Padding Padding
Janet
Systems
 Register  Login 
Telephone  01628 566 178
Website Design, Hosting and Software Services
  Search 
Padding
corner Padding corner
Padding Padding
corner Padding corner
 Javascript Articles
Javascript can access the history of the web browser through the history object. This object holds information about the URLs which have been visited both before and after the current one. Using the history object we are able to single step backwards and forwards through this list, and jump to any point.

The history object has four properties:

  • history.length keeps track of the length of the history list.
  • history.current is the value of the current history entry.
  • history.next is the next entry in the list.  This is equivelent to pressing the forward button on the browser.  It is therefore quire likley that it will have no value.
  • history.previous is the page before, equivelent to pressing the back button on the browser.

The history list may also be treated as an array. So we can access hiistory[0].

And finaly there are three methods:

  • history.forward the same as history.next
  • history.back the same as history.previous
  • history.go the equivelent to pushing either the forward or back button a number of times. For example history.go(-3) is equivelent to pressing the back button 3 times.

This article viewed: 2938 times Back

Copyright © 2004-2007 Janet Systems Ltd.

 Print   

DotNetNuke Website design and hosting from £15.00 per month. More...

Looking for a website design company in the Thames Valley, call us on 01628 566178

DotNetNuke Modules
DotNetNuke Modules availalble from Janet Systems

DotNetNuke Skins
DotNetNukeSkins.gif

from Janet Systems

Padding
Copyright 2002-2008 Janet Systems Ltd.   Terms Of Use  Privacy Statement Tuesday, May 13, 2008