This article mainly introduces how to automatically close the prompt box of the DIV layer at regular intervals in Javascript. It can load JavaScript code during loading and control the effect of automatically closing the prompt box at the div layer, which is very simple and practical, for more information about how to automatically disable the DIV prompt box in Javascript, see the example in this article. Share it with you for your reference. The specific analysis is as follows:
Here, we use JS to set the time to control whether the DIV layer of the specified ID is displayed. We can implement an automatic closing prompt box. Once the time is reached, close immediately. This will make your webpage more human, the code is actually simpler than you think, just a line of code.
Automatically closed DIV LayerFriendly reminder: This layer will disappear in 5 seconds!
I hope this article will help you design javascript programs.