检测浏览器的信息

Posted on 2012-09-19 11:39  剑竹  阅读(182)  评论(0)    收藏  举报

<html>

<body>

<script type="text/javascript">

document.write("<p>Browser: ") ;

document.write(navigator.appName + "</p>");

document.write("<p>Browserversion: ");

document.write(navigator.appVersion + "</p>");

document.write("<p>Code: ") ;

document.write(navigator.appCodeName + "</p>");

document.write("<p>Platform: ");

document.write(navigator.platform + "</p>");

document.write("<p>Cookies enabled: ") ;

document.write(navigator.cookieEnabled + "</p>");

document.write("<p>Browser's user agent header: ") ;

document.write(navigator.userAgent + "</p>") ;

</script>

</body>

</html>

博客园  ©  2004-2025
浙公网安备 33010602011771号 浙ICP备2021040463号-3