首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 网站开发 > CSS >

JSP include 处置IECSS不兼容

2012-10-27 
JSPinclude 处理IECSS不兼容%@ page languagejava importjava.util.* pageEncodingUTF-8%%Str

JSP include 处理IECSS不兼容

<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%><%String path = request.getContextPath();String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";%><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><%int w1=6,w2=6;String ie=request.getHeader("User-Agent"); //得到浏览器等相关信息if(ie.indexOf("MSIE")!=-1) {//这里是msie 即微软 ie浏览器out.write("<link rel='stylesheet' href='css/ie.css' type='text/css' />");}else{out.write("<link rel='stylesheet' href='css/other.css' type='text/css' />");}%>

?

热点排行