javascript navigator oscpu
| oscpu | NN 6 IE n/a DOM n/a |
|
|
Read-only |
|
Returns a string containing operating system or central processing unit information about the client machine. Values vary widely across systems. Windows clients are divided roughly into two categories: non-NT and NT. The former includes Windows 95, 98, and ME (oscpu values of Win95, Win98, and Win 9x 4.90, respectively). The NT category includes Windows NT 4 (WinNT4.0) and Windows XP (Windows NT x.x). Macintosh systems all report the CPU type and the absence or presence of Mac OS X (PPC or PPC Mac OS X). Unix systems report both the operating system and CPU type. The oscpu value is also a part of the userAgent value. Formatting for this information is not the same in Internet Explorer's corresponding cpuClass or userAgent properties. |
|
| Example | |
if (navigator.oscpu.indexOf("Win") != -1) {
document.write("You are running a Windows computer.");
}
|
|
| Value | |
|
String. |
|
| Default | |
|
System dependent. |
|
