history

作者: 洛洛kkkkkk | 来源:发表于2017-04-20 19:18 被阅读0次
<!DOCTYPE html>
<html>
    <head>
        <meta charset="UTF-8">
        <title></title>
        <style type="text/css">
            
        </style>
    </head>
    <body>
        <a href="history2.html">dasdsa</a>
    </body>
    <script type="text/javascript">
        //history
//      console.log(window.history);
//      history.back();
//      setTimeout(function () {
//          history.forward();
//      },2000)

//      history代表了房钱页面的历史记录,这个记录浏览器的记录不一样.代表了只有当前页面跳转过的页面.
//      length属性代表了当前历史记录中的个数
//      三个方法.
//      back forward go
//      back() 返回上一页
//      forward()去下一页
//      go()去某一个页面,go(-2) 代表2次back()
        setTimeout(function () {
            window.open("history2.html","_self",false);
        },2000)
        
    </script>
</html>

相关文章

网友评论

      本文标题:history

      本文链接:https://www.haomeiwen.com/subject/euolzttx.html