浏览器禁用返回按钮

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

 

posted @ 2019-08-15 20:37  酷酷的城池  阅读(495)  评论(0)    收藏  举报