Global Index
HTML5 JS API Index > Browser Tutorials & Specs

History

The joint session history of a top-level browsing context is the union of all the session histories of all browsing contexts of all the fully active Document objects that share that top-level browsing context, with all the entries that are current entries in their respective session histories removed except for the current entry of the joint session history.

Properties
long
length
The length attribute of the History interface must return the number of entries in the top-level browsing context's joint session history.
any
state
The state attribute of the History interface must return the last value it was set to by the user agent. Initially, its value must be null.
Operations
void
back()
When the back() method is invoked, the user agent must traverse the history by a delta −1.
void
forward()
When the forward()method is invoked, the user agent must traverse the history by a delta +1.
void
go(optional long delta)
When the go(delta) method is invoked, if the argument to the method was omitted or has the value zero, the user agent must act as if the location.reload() method was called instead. Otherwise, the user agent must traverse the history by a delta whose value is the value of the method's argument.
void
pushState(any data, DOMString title, optional DOMString? url)
The pushState(data, title, url) method adds a state object entry to the history.
void
replaceState(any data, DOMString title, optional DOMString? url)
The replaceState(data, title, url) method updates the state object, title, and optionally the URL of the current entry in the history.
Referenced by
Windowhistory