popin localstorage once

Solutions on MaxInterview for popin localstorage once by the best coders in the world

showing results for - "popin localstorage once"
Jona
02 Apr 2020
1$j(document).ready(function() {
2    if(localStorage.getItem('popState') != 'shown'){
3        $j("#popup").delay(2000).fadeIn();
4        localStorage.setItem('popState','shown')
5    }
6
7    $j('#popup-close, #popup').click(function(e) // You are clicking the close button
8    {
9        $j('#popup').fadeOut(); // Now the pop up is hiden.
10    });
11});