开发者

How can I detect the browser version with JS?

开发者 https://www.devze.com 2023-01-05 02:57 出处:网络
I need to detect the OS version with JS not jus开发者_高级运维t the OS type. Is this possible?My navigator.userAgent in Firefox shows :

I need to detect the OS version with JS not jus开发者_高级运维t the OS type.

Is this possible?


My navigator.userAgent in Firefox shows :

"Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2.6) Gecko/20100625 Firefox/3.6.6"

In chrome:

"Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US) AppleWebKit/533.4 (KHTML, like Gecko) Chrome/5.0.375.86 Safari/533.4"

In IE8:

"Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; .NET CLR 2.0.50727; .NET CLR 3.0.04506.6

So apparently for my particular OS/Browsers combination is possible, but I would not really count on that working everywhere.

0

精彩评论

暂无评论...
验证码 换一张
取 消