亚洲国产日韩欧美一区二区三区,精品亚洲国产成人av在线,国产99视频精品免视看7,99国产精品久久久久久久成人热,欧美日韩亚洲国产综合乱

javascript - Browser rollback, how to ensure that js operations on dom are saved
僅有的幸福
僅有的幸福 2017-06-26 10:54:39
0
3
837

1. There are multiple external links written on the homepage;
2. When you enter the homepage, a pop-up window will be displayed. When it is clicked to close, use the js click event to set the display of the pop-up window to none and hide the pop-up window;
3. Click to enter other link pages, and then go back through the browser's back button or Android phone WeChat. It will return to the homepage, but the pop-up window will pop up again. Is there any solution? After going back, you don’t want the pop-up window to be displayed, and it will be displayed as the state before the jump

僅有的幸福
僅有的幸福

reply all(3)
巴扎黑

Set a cookie, record the status, and enter the page to determine whether there is a cookie. If there is a cookie, there will be no pop-up window. If not, there will be a pop-up window.

扔個(gè)三星炸死你

As mentioned above, using cookies, jquery’s cookie is particularly simple. If you don't consider supporting IE browser, you might as well use h5's new features localstorage or sessionstorage.

阿神

Cookie, localstorage; there is also an event popstate that may be used in conjunction with history.pushState
cookie should be able to achieve the effect.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template