Java教程

javascript当中navigator的用法

本文主要是介绍javascript当中navigator的用法,对大家解决编程问题具有一定的参考价值,需要的程序猿们随着小编来一起学习吧!

3.navigator
例 1.3(navigatorIEFF.html)
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
<TITLE> New Document </TITLE>
<META NAME="Generator" CONTENT="EditPlus">
<META NAME="Author" CONTENT="">
<META NAME="Keywords" CONTENT="">
<META NAME="Description" CONTENT="">
</HEAD>
<BODY>
<SCRIPT LANGUAGE="JavaScript">
<!--
for(var p in navigator)
{
/*Window.navigator (Property)
A reference to a navigator object that describes the browser.*/
     document.write("属性"+p+"的属性值为:"+navigator[p]+"<br>");
}
//-->
</SCRIPT>
</BODY>
</HTML>

更多内容请见原文,文章转载自:https://blog.csdn.net/qq_43650923/article/details/103042952

这篇关于javascript当中navigator的用法的文章就介绍到这儿,希望我们推荐的文章对大家有所帮助,也希望大家多多支持为之网!