The history history object in JavaScript contains information about the URL that the user has browsed, referring to the browsing history of the browser as a historical object. Given the need for security, the object receives a lot of restrictions and now only has the following properties and methods left. The history history object has the attribute of length, which lists the number of items in the history. The history that JavaScript can manage is limited to the range that the "forward" and "back" keys of the browser can go to. This property returns the and of the number of addresses that are contained under "forward" and "back" two keys.
History historical objects and has the following methods
Back () is equivalent to pressing the back key.
Forward () forward, is equivalent to pressing the "forward" key.
Go () Usage: history.go (x); In the range of history to a specified address. If x < 0, back x address, if x > 0, Forward x address, if x = = 0, refresh the page that is now open. History.go (0) is equivalent to Location.reload ().
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.