H5Check.jsp 1.01 KB
<%@ page language="java" contentType="text/html; charset=UTF-8" %>
<%@ include file="/mobilemode/init2.jsp"%>
<%
String url = request.getParameter("url");
%>
<script type="text/javascript">
    var userAgent = navigator.userAgent; //取得浏览器的userAgent字符串
    var isIe = userAgent.indexOf("compatible") > -1 && userAgent.indexOf("MSIE") > -1; //ie10及以下
    var isIe11  = userAgent.indexOf('Trident') > -1 && userAgent.indexOf("rv:11.0") > -1; //ie11
    if(isIe || isIe11){	//IE
        window.location.href = "/mobilemode/unsupporthtml5_wev8.jsp";
    }else{
        window.location.href = "<%=url%>";
    }
/*var pass = true;
if(navigator.userAgent.indexOf("MSIE")!=-1){	//IE
	
	var strVer = window.navigator.appVersion;
	var iev = 0;
	if(strVer.substr(17,4)=="MSIE"){
		iev = strVer.substr(22,(strVer.indexOf(";", 22) - 22));
	}
	iev = parseInt(iev);
	
	if(iev < 10){
		pass = false;
	}
}
if(pass){
window.location.href = "";
}else{
	window.location.href = "/mobilemode/unsupporthtml5_wev8.jsp";
}*/
</script>