最新国产好看的视频,伊人天堂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
桃园县| 交城县| 古田县| 靖远县| 永修县| 萝北县| 冀州市| 曲周县| 新竹市| 宜州市| 安西县| 济源市| 乌拉特中旗| 宁陕县| 遵义市| 民县| 灵宝市| 方山县| 石渠县| 太和县| 河西区| 福安市| 石棉县| 武邑县| 怀宁县| 彭州市| 静海县| 霍林郭勒市| 香港 | 象州县| 体育| 阳新县| 呈贡县| 张家口市| 当阳市| 阳高县| 阿尔山市| 盖州市| 通州市| 铜山县| 西乌珠穆沁旗|