var ms_ie = false; var ua = window.navigator.userAgent.toLowerCase(); var old_ie = ua.indexOf('MSIE'); var new_ie = ua.indexOf('trident/'); var is360 = false; var append = document.getElementById("append"); if((old_ie > -1) || (new_ie > -1
<script type="text/javascript"> var lang = (navigator.systemLanguage?navigator.systemLanguage:navigator.language); //获取浏览器配置语言 #括号内是个运算,运算过后赋值给lang,当?前的内容为true时把?后的值赋给lang,为False时把:后的值赋给lang var lang = lang.substr(0, 2);//获取lang字符串的前两位 if(
var DEFAULT_VERSION = 8.0; var ua = navigator.userAgent.toLowerCase(); var isIE = ua.indexOf("msie")>-1; var safariVersion; if(isIE){ safariVersion = ua.match(/msie ([\d.]+)/)[1]; } if(safariVersion <= DEFAULT_VERSION ){ alert('系统检测到您正在使用i
var version = navigator.userAgent; console.log(version); //"Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/63.0.3223.0 Safari/537.36" if(version.indexOf("Windows NT 5")!=-1) { console.log("这是XP系
一.js检查flash版本升级 for (var i = 0, len = navigator.plugins.length; i < len; i++) { var plugin = navigator.plugins[i]; if (plugin.name == 'Shockwave Flash') { if (plugin.filename == 'internal-not-yet-present') { commFunc.confirm("您当前浏览器flash插件版本较低,可能无