最新国产好看的视频,伊人天堂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
华亭县| 安义县| 双牌县| 承德县| 邵东县| 永年县| 锦屏县| 旬邑县| 鱼台县| 垣曲县| 富裕县| 稷山县| 佳木斯市| 揭东县| 玛多县| 阳新县| 普洱| 宁乡县| 平山县| 牙克石市| 四会市| 桃园县| 漠河县| 周口市| 开江县| 金塔县| 广宁县| 云和县| 绩溪县| 四平市| 铁力市| 尉犁县| 视频| 札达县| 滦平县| 福泉市| 云和县| 永仁县| 师宗县| 松原市| 永德县|