Get the App
SLTechnology News&Howtos  ›  Development  › 

What is JavaScript window navigator?

Shulou Source: shulou.com Published: 2022-06-03 08:22:13 10月01日 Update

This article will explain in detail what is JavaScript window navigator, the content of the article is of high quality, so the editor will share it with you for reference. I hope you will have a certain understanding of the relevant knowledge after reading this article.

The window.navigator object contains information about the visitor's browser.

1. Window Navigator

Window.navigator objects can be written without the window window prefix (navigator.XXXX).

II. Attributes

1. Browser Cookies

The cookieEnabled property returns true if Cookie is enabled, otherwise false.

Project Navigator object

The cookieEnabled property returns true if cookies is enabled:

Document.getElementById ("demo") [xss_clean] = "navigator.cookieEnabled is" + navigator.cookieEnabled

two。 Browser application name

The appName property returns the application name of the browser.

Document.getElementById ("demo") [xss_clean] = "navigator.appName is" + navigator.appName

Note:

"Netscape" is the application name for IE11, Chrome, Firefox, and Safari.

3. Project browser application code name

The appCodeName property returns the application code name of the browser.

Document.getElementById ("demo") [xss_clean] =

"navigator.appCodeName is" + navigator.appCodeName

"Mozilla" is the name of the Chrome, Firefox, IE, Safari and Opera application code.

4. Browser engine

The product property returns the product name of the browser engine:

Document.getElementById ("demo") [xss_clean] =

"navigator.product is" + navigator.product

5. Browser version

The appVersion property returns version information about the browser.

Document.getElementById ("demo") [xss_clean] = navigator.appVersion; on what is JavaScript window navigator to share here, I hope the above content can be of some help to you, can learn more knowledge. If you think the article is good, you can share it for more people to see.

Tags: Browsers properties names applications programs applications code objects related products information content engines articles more versions knowledge articles projects Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Microsoft Shulou Tech Info NVidia Shulou Information macOS