• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint

The history Object

The Web browser also maintains a list of pages that you have visited since running the program; this list is called the history list, and it can be accessed through the history object. Your JavaScript programs can move through pages in the list by using the properties and functions shown in Table 19.2.

The history.length, therefore, would return the number of entries in the history list. The methods history.back() and history.forward() would cause the Web browser to load the previous and next entry in the history list, if any.


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint