This code was working until about 30mins ago and now it suddenly ceases to work. It is simple and I am completely unable to see what is wrong with it or anything else that could be the reason for it not working. Can somebody help?`
<?php
$cookie_name = "Name";
$cookie_value = "Value";
if(!isset($_COOKIE[$cookie_name])) {
setcookie($cookie_name, $cookie_value, time() + 10, "/");
include 'popup.html';
}
?>
What should happen is that it pops up a small Ad for users and then ads a cookie to stop it from popping up again. I had it set to expire after 10 seconds for testing but even if I set it to one week, the popup always appears. Like I mentioned before, it was working. Perfectly.