0 评论
408 浏览

新秀history.go方法改变页面的应用

  Go 方法  如果您想向前或向后移动 n 个页面,那么您可以使用 go 方法:  <pre class="has">history.go(-2) // 倒退 2 页 history.go(2) // 前进 2 页...

0 评论
418 浏览

新秀window.history属性指向History对象的操作方法与方法设置

  作者 | 阮一峰  1、概述  window.history属性指向 History 对象,它表示当前窗口的浏览历史。  History 对象保存了当前窗口访问过的所有页面网址。下面代码表示当前窗口一共访问过3个网址。 ...

!