이 문서는 아직 자원 봉사자들이 한국어로 번역하지 않았습니다. 함께 해서 번역을 마치도록 도와 주세요!
Returns a string representing the platform of the browser. The specification allows browsers to always return the empty string, so don't rely on this property to get a reliable answer.
Syntax
platform = navigator.platform
Value
A DOMString
. platform
is a string that must be an empty string or a string representing the platform on which the browser is executing.
For example: "MacIntel
", "Win32
", "FreeBSD i386
", "WebTV OS
"
Example
console.log(navigator.platform);
Notes
On Firefox, unless your code is privileged (that is, running in chrome or at least has the UniversalBrowserRead
privilege), it may get the value of the general.platform.override
preference instead of the true platform.
Specifications
Specification | Status | Comment |
---|---|---|
WHATWG HTML Living Standard The definition of 'NavigatorID.platform' in that specification. |
Living Standard | Initial definition. |
Browser compatibility
Feature | Chrome | Firefox (Gecko) | Internet Explorer | Opera | Safari |
---|---|---|---|---|---|
Basic support | (Yes) | (Yes) | (Yes) | (Yes) | (Yes) |
Feature | Android | Chrome for Android | Firefox Mobile (Gecko) | IE Mobile | Opera Mobile | Safari Mobile |
---|---|---|---|---|---|---|
Basic support | (Yes) | (Yes) | (Yes) | (Yes) | (Yes) | (Yes) |
문서 태그 및 공헌자
태그:
이 페이지의 공헌자:
Sheppy,
teoli,
chrisdavidmills,
0xdeadcafe,
kscarfone,
Rob W,
ziyunfei,
Marcoos,
Mgjbot,
Diablownik,
Nickolay,
Jabez,
Dria,
JesseW
최종 변경:
Sheppy,