History object (Object/browser)

A history object owned by the window. This exposes information about URLs that have been visited previously.

Availability:

JavaScript - 1.0
JScript - 1.0
Internet Explorer - 3.02
Netscape - 2.0
Opera - 3.0
JavaScript syntax:-myHistory = history
-myHistory = myWindow.history
Object properties:current, length, next, previous
Object methods:back(), forward(), go()

Netscape version 4 provides access to the history array by signed scripts. Earlier versions of Netscape and MSIE do not provide this level of access and therefore the history object is limited in what you can do with it.

Some properties can be accessed by non-privileged scripts.

In Netscape, each element in the History object array is a String containing the URL for that item in the history. In MSIE, the objects are not accessible directly.

Warnings:

See also:Collection object, UniversalBrowserAccess, UniversalBrowserRead, Window.history

PropertyJavaScriptJScriptNIEOperaNESECMADOMCSSHTMLNotes
current1.1 1.1 n/a3.0 3.0 n/a3.0 3.0 n/a n/a n/a n/a n/aWarning , ReadOnly.
length1.0 1.01.0 1.02.0 2.03.02 3.023.0 3.0 n/a n/a n/a n/a n/aReadOnly.
next1.1 1.1 n/a3.0 3.0 n/a3.0 3.0 n/a n/a n/a n/a n/aWarning , ReadOnly.
previous1.1 1.1 n/a3.0 3.0 n/a3.0 3.0 n/a n/a n/a n/a n/aWarning , ReadOnly.

MethodJavaScriptJScriptNIEOperaNESECMADOMCSSHTMLNotes
back()1.0 1.01.0 1.02.0 2.03.02 3.023.0 3.0 n/a n/a n/a n/a n/a-
forward()1.0 1.01.0 1.02.0 2.03.02 3.023.0 3.0 n/a n/a n/a n/a n/a-
go()1.0 1.01.0 1.02.0 2.03.02 3.023.0 3.0 n/a n/a n/a n/a n/aWarning