Javascript navigator appName property returns the name of the client web browser. appName property of Javascript navigator object enables you to run the part of javascript based on the name of the web browser returned by it. You can skip the Javascript code that consists of objects not supported by the client’s browser according to the name of the browser returned by the appName property of navigator object.
navigator.appName
or
window.navigator.appName
You can use window.navigator also to access the appName property. Both above code syntax for javascript navigator appName objects return the same information about the web browser of the client’s system.
<script language="javascript" type="text/javascript">
document.write(navigator.appName);
</script>
Above example of appName property of navigator object returns the following output for different web browsers:
In Internet Explorer navigator.appName returns:
Output: Microsoft Internet Explorer
In FireFox navigator.appName returns:
Output: Netscape
In Opera web browser navigator.appName returns:
Output: Opera
Be the first to rate this post
Tags: javascript, javascript navigator appname, javascript window navigator, javascript browser detection, javascript navigator object, javascript navigator properties, javascript navigator.appname, javascript navigator.appversion, javascript navigator.useragent, check cookies enabled
10/11/2008 3:26:28 AM