首页 > Web开发 > 详细

JS - IE or not:判断是否为IE浏览器方法

时间:2015-08-13 17:13:03      阅读:116      评论:0      收藏:0      [点我收藏+]

问题:使用JS判断是否为IE浏览器

方法:

1.IE=‘\v‘==‘v‘

if(‘\v‘==‘v‘) // true only in IE

 

2.IE=(!+"\v1")

if(!+"\v1") // true only in IE

3.IE=top.execScript?1:0

if(top.execScript?true:false) // true only in IE

 

JS - IE or not:判断是否为IE浏览器方法

原文:http://www.cnblogs.com/tx8899/p/4727487.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!