Home > Web Front-end > JS Tutorial > js code to identify whether the operating system is vista_javascript skills

js code to identify whether the operating system is vista_javascript skills

WBOY
Release: 2016-05-16 19:09:35
Original
983 people have browsed it

How to use ASP to identify that the operating system is Vista? I found a function on the Internet, but I can’t tell if it is a Vista system. I hope you can help.
This is the function I found on the Internet:
Function GetCurrOS()
Dim Info
Info = navigator.appVersion
If Instr(info,"NT 5.1")>0 Then
GetCurrOS = "Windows XP"
ElseIf Instr(info,"Tel") >0 Then
 GetCurrOS = "Telport"
ElseIf Instr(info,"webzip")>0 Then
GetCurrOS = "webzip"
ElseIf Instr(info,"flashget")> 0 Then
GetCurrOS = "flashget"
ElseIf Instr(info,"offline")>0 Then
GetCurrOS = "offline"
ElseIf Instr(info,"NT 5")>0 Then
 GetCurrOS = "Windows 2000"
ElseIf Instr(info,"NT 4")>0 Then
GetCurrOS = "Windows NT4"
ElseIf Instr(info,"98")> 0 Then
GetCurrOS = "Windows 98"
ElseIf Instr(info,"95")>0 Then
GetCurrOS = "Windows 95"
Else
GetCurrOS = "UnKnow"
End If
End Function
If you have a better function, please give one to me. Thanks in advance.


[Ctrl A select all Note: If you need to introduce external Js, you need to refresh to execute
]
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template