Name
Navigator: information about the browser in use â JavaScript 1.0: Object â Navigator
Synopsis
navigator
Properties
-
appCodeName
A read-only string that specifies the code name of the browser. In all browsers based on the Netscape code base (Netscape, Mozilla, Firefox), this is âMozillaâ. For compatibility, this property is âMozillaâ in Microsoft browsers as well.
-
appName
A read-only string property that specifies the name of the browser. For Netscape-based browsers, the value of this property is âNetscapeâ. In IE, the value of this property is âMicrosoft Internet Explorerâ. Other browsers may identify themselves correctly or spoof another browser for compatibility.
-
appVersion
A read-only string that specifies version and platform information for the browser. The first part of this string is a version number. Pass the string to
parseInt( )
to obtain only the major version number or toparseFloat( )
to obtain the major and minor version numbers as a floating-point value. The remainder of the string value of this property provides other details about the browser version, including the operating system it is running on. Unfortunately, however, the format of this information varies widely from browser to browser.-
cookieEnabled
A read-only boolean that is
true
if the browser has cookies enabled andfalse
if they are disabled.-
mimeTypes[]
An array of MimeType objects, each of which represents one of the MIME types (e.g., âtext/htmlâ and âimage/gifâ) supported ...
Get JavaScript: The Definitive Guide, 5th Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.