ﺩﺭﻮﻣ ﺭﺩ ﯽﺗﺎﻋﻼﻃﺍ ﯼﻭﺎﺣ window.navigator
ﯽﺷ
.ﺖﺷﻮﻧ ﻩﺮﺠﻨﭘ ﺪﻧﻮﺸﯿﭘ ﻥﻭﺪﺑ ﻥﺍﻮﺗ ﯽﻣ ﺍﺭ window.navigator
:ﻪﻧﻮﻤﻧ ﺪﻨﭼ
navigator.cookieEnabled
navigator.appCodeName
navigator.platform
ﺕﺭﻮﺻ ﻦﯾﺍ ﺮﯿﻏ ﺭﺩ ،ﺪﻧﺍﺩﺮﮔﯽﻣﺮﺑ ﺍﺭ code class="w3-codespan">cookieEnabled tru
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML =
"cookiesEnabled is " + navigator.cookieEnabled;
</script>
→ ﺪﯿﻨﮐ ﻥﺎﺤﺘﻣﺍ ﺍﺭ ﻥﺁ ﻥﺎﺗﺩﻮﺧ
<!DOCTYPE html>
<html>
<body>
<h2>The Navigator Object</h2>
<p>The cookieEnabled property returns true if cookies are enabled:</p>
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML =
"navigator.cookieEnabled is " + navigator.cookieEnabled;
</script>
</body>
</html>
ﺪﻧﺍﺩﺮﮔﯽﻣﺮﺑ ﺍﺭ ﻪﻣﺎﻧﺮﺑ ﻡﺎﻧ appName
ﯽﮔﮋﯾﻭ
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML =
"navigator.appName is " + navigator.appName;
</script>
→ ﺪﯿﻨﮐ ﻥﺎﺤﺘﻣﺍ ﺍﺭ ﻥﺁ ﻥﺎﺗﺩﻮﺧ
<!DOCTYPE html>
<html>
<body>
<h2>The Navigator Object</h2>
<p>The appName property returns the application name of the browser:</p>
<p id="demo"></p>
<p>Strange enough, "Netscape" is the application name for IE11, Chrome, Firefox, and Safari.</p>
<script>
document.getElementById("demo").innerHTML =
"navigator.appName is " + navigator.appName;
</script>
</body>
</html>
.(ﻩﺪﺷ ﺥﻮﺴﻨﻣ) ﺖﺳﺍ ﻩﺪﺷ ﻑﺬﺣ ﺏﻭ ﺩﺭﺍﺪﻧﺎﺘﺳﺍ ﻦﯾﺮﺧﺁ ﺭﺩ ﯽﮔﮋﯾﻭ ﻦﯾﺍ
.ﺪﻨﻧﺍﺩﺮﮔﯽﻣﺮﺑ appName ﻥﺍﻮﻨﻋ ﻪﺑ ﺍﺭ Netscape (IE11، Chrome، Firefox، Safari)
ﺪﻧﺍﺩﺮﮔﯽﻣﺮﺑ ﺍﺭ ﻪﻣﺎﻧﺮﺑ ﺪﮐ ﻡﺎﻧ appCodeName
ﯽﮔﮋﯾﻭ
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML =
"navigator.appCodeName is " + navigator.appCodeName;
</script>
→ ﺪﯿﻨﮐ ﻥﺎﺤﺘﻣﺍ ﺍﺭ ﻥﺁ ﻥﺎﺗﺩﻮﺧ
<!DOCTYPE html>
<html>
<body>
<h2>JavaScript Navigator</h2>
<p>The appCodeName property returns the code name of the browser.</p>
<p>Do not rely on it! "Mozilla" is the application code name for Chrome, Firefox, IE, Safari, and Opera.</p>
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML =
"navigator.appCodeName is " + navigator.appCodeName;
</script>
</body>
</html>
.(ﻩﺪﺷ ﺥﻮﺴﻨﻣ) ﺖﺳﺍ ﻩﺪﺷ ﻑﺬﺣ ﺏﻭ ﺩﺭﺍﺪﻧﺎﺘﺳﺍ ﻦﯾﺮﺧﺁ ﺭﺩ ﯽﮔﮋﯾﻭ ﻦﯾﺍ
.ﺪﻨﻧﺍﺩﺮﮔﯽﻣﺮﺑ appCodeName ﻥﺍﻮﻨﻋ ﻪﺑ ﺍﺭ Mozilla (IE11، Chrome، Firefox، Safa
ﺩﺩﺮﮔﯽﻣﺮﺑ product
ﯽﮔﮋﯾﻭ
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML =
"navigator.product is " + navigator.product;
</script>
→ ﺪﯿﻨﮐ ﻥﺎﺤﺘﻣﺍ ﺍﺭ ﻥﺁ ﻥﺎﺗﺩﻮﺧ
<!DOCTYPE html>
<html>
<body>
<h2>The Navigator Object</h2>
<p>The product property returns the product name of the browser.</p>
<p>Do not rely on it! Most browsers returns "Gecko" as product name!</p>
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML =
"navigator.product is " + navigator.product;
</script>
</body>
</html>
.(ﻩﺪﺷ ﺥﻮﺴﻨﻣ) ﺖﺳﺍ ﻩﺪﺷ ﻑﺬﺣ ﺏﻭ ﺩﺭﺍﺪﻧﺎﺘﺳﺍ ﻦﯾﺮﺧﺁ ﺭﺩ ﯽﮔﮋﯾﻭ ﻦﯾﺍ
.ﺪﻨﻧﺍﺩﺮﮔ ﯽﻣﺮﺑ ﻝﻮﺼﺤﻣ ﻥﺍﻮﻨﻋ ﻪﺑ ﺍﺭ Gecko ﺎﻫﺮﮔﺭﻭﺮﻣ ﺮﺜﮐﺍ
ﺩﺩﺮﮔﯽﻣﺮﺑ appVersion
ﯽﮔﮋﯾﻭ
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML = navigator.appVersion;
</script>
→ ﺪﯿﻨﮐ ﻥﺎﺤﺘﻣﺍ ﺍﺭ ﻥﺁ ﻥﺎﺗﺩﻮﺧ
<!DOCTYPE html>
<html>
<body>
<h2>The Navigator Object</h2>
<p>The appVersion property returns version information about the browser:</p>
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML = navigator.appVersion;
</script>
</body>
</html>
:ﺪﻧﺍﺩﺮﮔ ﯽﻣﺮﺑ ﺭﻭﺮﺳ ﻪﺑ ﺍﺭ ﺮﮔﺭﻭﺮﻣ ﻂﺳﻮﺗ ﻩﺪﺷ ﻝﺎﺳﺭﺍ user-agent ﺭﺪﻫ → ﺪﯿﻨﮐ ﻥﺎﺤﺘﻣﺍ ﺍﺭ ﻥﺁ ﻥﺎﺗﺩﻮﺧ ﻝﺎﺜﻣ
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML = navigator.userAgent;
</script>
<!DOCTYPE html>
<html>
<body>
<h2>The Navigator Object</h2>
<p>The userAgent property returns the user-agent header sent by the browser to the server:</p>
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML =
navigator.userAgent;
</script>
</body>
</html>
.ﺪﺷﺎﺑ ﻩﺪﻨﻨﮐ ﻩﺍﺮﻤﮔ ﺪﻧﺍﻮﺗ ﯽﻣ ﺐﻠﻏﺍ ﺮﺑﻭﺎﻧ ﯽﺷ ﺯﺍ ﺕﺎﻋﻼﻃﺍ
:ﺍﺮﯾﺯ ﺩﻮﺷ ﻩﺩﺎﻔﺘﺳﺍ ﺮﮔﺭﻭﺮﻣ ﯼﺎﻫ ﻪﺨﺴﻧ ﯽﯾﺎﺳﺎﻨﺷ ﯼﺍﺮﺑ ﺪﯾﺎﺒﻧ ﺮﺑﻭﺎﻧ ﯽﺷ
ﺪﻨﻨﮐ ﻩﺩﺎﻔﺘﺳﺍ ﻡﺎﻧ ﮏﯾ ﺯﺍ ﺪﻨﻧﺍﻮﺗ ﯽﻣ ﻒﻠﺘﺨﻣ ﯼﺎﻫﺮﮔﺭﻭﺮﻣ
ﺪﻨﻧﺍﻮﺗ ﯽﻣ ﺮﺑﻭﺎﻧ ﯼﺎﻫ ﻩﺩﺍﺩ
ﺪﻨﻨﮐ ﯽﻣ ﯽﯾﺎﺳﺎﻨﺷ ﻩﺎﺒﺘﺷﺍ ﺍﺭ ﺩﻮﺧ ،ﺖﯾﺎﺳ ﯼﺎﻫ ﺖﺴﺗ ﻥﺩﺯ ﺭﻭﺩ ﯼﺍﺮﺑ ﺎﻫﺮﮔﺭﻭﺮﻣ ﺯﺍ ﯽﺧﺮﺑ
ﺪﻨﻫﺩ ﺵﺭﺍﺰﮔ ﺪﻧﺍ ﻩﺪﺷ ﺮﺸﺘﻨﻣ ﺮﮔﺭﻭﺮﻣ ﺯﺍ ﺮﺗﺮﯾﺩ ﻪﮐ ﺍﺭ ﯼﺪﯾﺪﺟ ﯼﺎﻫ ﻞﻣﺎﻋ ﻢﺘﺴﯿﺳ ﺪﻨﻧﺍﻮﺗ ﯽﻤﻧ ﺎﻫﺮﮔﺭﻭ
ﺪﻧﺍﺩﺮﮔ ﯽﻣﺮﺑ ﺍﺭ ﺮﮔﺭﻭﺮﻣ ﻡﺮﻓ ﺖﻠﭘ platform
ﯽﮔﮋﯾﻭ
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML = navigator.platform;
</script>
→ ﺪﯿﻨﮐ ﻥﺎﺤﺘﻣﺍ ﺍﺭ ﻥﺁ ﻥﺎﺗﺩﻮﺧ
<!DOCTYPE html>
<html>
<body>
<h2>The Navigator Object</h2>
<p>The platform property returns the browser platform (operating system):</p>
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML =
"navigator.platform is " + navigator.platform;
</script>
</body>
</html>
:ﺪﻧﺍﺩﺮﮔﯽﻣﺮﺑ ﺍﺭ ﺮﮔﺭﻭﺮﻣ ﻥﺎﺑﺯ language
ﯽﮔﮋﯾﻭ
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML = navigator.language;
</script>
→ ﺪﯿﻨﮐ ﻥﺎﺤﺘﻣﺍ ﺍﺭ ﻥﺁ ﻥﺎﺗﺩﻮﺧ
<!DOCTYPE html>
<html>
<body>
<h2>The Navigator Object</h2>
<p>The language property returns the browser's language:</p>
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML =
"navigator.language is " + navigator.language;
</script>
</body>
</html>
:ﺪﻧﺍﺩﺮﮔﯽﻣﺮﺑ ﺍﺭ code class="w3-codespan">onLine true> ﯽﮔﮋﯾﻭ ،ﺪﺷﺎﺑ ﻦﯾﻼﻧﺁ ﺮﮔ
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML = navigator.onLine;
</script>
→ ﺪﯿﻨﮐ ﻥﺎﺤﺘﻣﺍ ﺍﺭ ﻥﺁ ﻥﺎﺗﺩﻮﺧ
<!DOCTYPE html>
<html>
<body>
<h2>The Navigator Object</h2>
<p>The onLine property returns true if the browser is online:</p>
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML =
"navigator.onLine is " + navigator.onLine;
</script>
</body>
</html>
:ﺪﻧﺍﺩﺮﮔﯽﻣﺮﺑ ﺍﺭ code class="w3-codespan">javaEnabled() true> ﺵﻭﺭ ،ﺪﺷﺎﺑ ﻝﺎﻌ
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML = navigator.javaEnabled();
</script>
→ ﺪﯿﻨﮐ ﻥﺎﺤﺘﻣﺍ ﺍﺭ ﻥﺁ ﻥﺎﺗﺩﻮﺧ
<!DOCTYPE html>
<html>
<body>
<h2>The Navigator Object</h2>
<p>The javaEnabled() method returns true if Java is enabled:</p>
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML =
"javaEnabled is " + navigator.javaEnabled();
</script>
</body>
</html>