最新国产好看的视频,伊人天堂AV在线,国产Aaaaaa视频,蜜臀视频在线观看一区,人妻av色图,密臀久久久精品影片,青青视频免费观看毛片,久草在线观看视,国产三级精品色情在线

userAgent Property

Internet Development Index

Retrieves a string equivalent to the HTTP user-agent request header.

Syntax

[ sUserAgent = ] object.userAgent

Possible Values

sUserAgentString爐hat specifies a valid HTTP user agent.

The property is read-only. The property has no default value.

Remarks

The HTTP user-agent request header contains information about compatibility, the browser, and the platform name. For more information about the browser, see the appName property. For more information about the platform, see the appVersion property.

The userAgent property dynamically returns a different value depending on the browser and platform versions. For example, Microsoft® Internet Explorer 6 returns the following string for Microsoft Windows® XP.

Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)

Examples

This example uses the userAgent property to specify a required platform before additional script is executed. For example, if Windows XP is a requirement for the document, you can use a variable to determine whether the user is running the necessary operating system. The "bIsXP" variable is set to true if Windows XP is found in the userAgent value and the additional script is processed.

<SCRIPT>
var bIsXP=false;
window.onload=fnInit;
function fnInit(){
if(navigator.userAgent.indexOf("Windows NT 5.1")>-1){
bIsXP=true;
}
if(bIsXP==true){
// Process additional script.
}
}
</SCRIPT>

Standards Information

There is no public standard that applies to this property.

Applies To

clientInformation, navigator

See Also

About Conditional Comments
申扎县| 兖州市| 类乌齐县| 乌苏市| 永年县| 聂拉木县| 五莲县| 海伦市| 宣威市| 化州市| 丹阳市| 金平| 双牌县| 双桥区| 绥化市| 蓬莱市| 嘉峪关市| 高密市| 东阳市| 肥城市| 黑龙江省| 台前县| 越西县| 临武县| 德庆县| 遂溪县| 林甸县| 浮山县| 佛坪县| 龙南县| 汝阳县| 大埔县| 宣城市| 福州市| 会宁县| 若尔盖县| 吴江市| 独山县| 马尔康县| 巴彦淖尔市| 德昌县|