<html>
<head>
<script type="text/javascript">
function GetBrowserVersion()
{
    var Sys = {};
    var ua = navigator.userAgent.toLowerCase();
    window.ActiveXObject ? Sys.ie = ua.match(/msie ([\d.]+)/)[1] :
    document.getBoxObjectFor ? Sys.firefox = ua.match(/firefox\/([\d.]+)/)[1] :
    window.MessageEvent && !document.getBoxObjectFor ? Sys.chrome = ua.match(/chrome\/([\d.]+)/)[1] :
    window.opera ? Sys.opera = ua.match(/opera.([\d.]+)/)[1] :
    window.openDatabase ? Sys.safari = ua.match(/version\/([\d.]+)/)[1] : 0;
    if(Sys.ie) return('IE: '+Sys.ie);
    if(Sys.firefox)return('FF:'+Sys.firefox);
    if(Sys.chrome) return('CH:'+Sys.chrome);
    if(Sys.opera) return('OP:'+Sys.opera);
    if(Sys.safari) return('SA:'+Sys.safari);
}
alert(GetBrowserVersion());
</script>
</head>
<body>
aa
</body>
</html>

相关文章:

  • 2022-12-23
  • 2021-10-22
  • 2022-03-04
  • 2021-11-23
猜你喜欢
  • 2022-12-23
  • 2021-10-03
  • 2021-10-19
  • 2022-12-23
  • 2021-12-31
相关资源
相似解决方案