js禁用后退

history.pushState(null, null, document.URL);
         window.addEventListener('popstate', function() {
            history.pushState(null, null, document.URL);

posted @ 2016-12-26 20:35  宝贝企鹅  阅读(140)  评论(0编辑  收藏  举报