<script type="text/javascript">
if(window.navigator.userAgent.indexOf("MSIE")>0){
//IE内核浏览器 针对IE8及以下 IE8以上都是使用的w3c内核
alert("IE");
}else{
//w3c内核浏览器
alert("W3C");
if(window.navigator.userAgent.indexOf("MSIE")>0){
//IE内核浏览器 针对IE8及以下 IE8以上都是使用的w3c内核
alert("IE");
}else{
//w3c内核浏览器
alert("W3C");
}
</script>