Hello,
I have the following code -
Code:
jQuery(document).ready(function(){
if (document.cookie.indexOf('visited=true') == -1) {
var fifteenDays = 1000*60*60*24*365;
var expires = new Date((new Date()).valueOf() + fifteenDays);
document.cookie = "visited=true;expires=" + expires.toUTCString();
}
});
I'm using it for a pop-up on a page on my website, giving users a reminder to register, and setting it to expire in 365 days.
However, within the pop-up I need some text saying "Remind Me Later" that will instead expire the cookie in 24 hours, so they get the pop-up again the next day.
Is this possible? Any help appreciated.