Javascript History Length Property

Updated on
23 Mar 2012,
Published on
25 Jul 2008

Javascript History length property returns the number of URLs stored in the browser history for the current session of browser windows being used by the visitor. Javascript history length property returns the number value based on the counting method of web browser for example Microsoft Internet Explorer counts the history URLs from 0, FireFox counts the history items from 1 and Opera web browser counts the history items from 0. You can also test the history length property by getting the initial value in each browser. FireFox returns history length value as 1 whereas Internet Explorer and Opera returns 0.

JavaScript History Object Examples:

You can see the live samples and examples of JavaScript History Object from the following links: