I was working on my website on localhost (where it worked correctly) and then I moved it to classic domain, but there is issue with PHP setcookie function.
Here is my setcookie sample, basically it will take data from URL paramater called "ID" and then save it as cookie and then it will redirect to website to hide URL paramater.
Yes it works on localhost, but on normal website no..I dont know what to do please help me :)
if (isset($_GET['id'])) {
$hafcookie = $_GET['id'];
setcookie( 'lolcookies', $hafcookie, time() + (10 * 365 * 24 * 60 * 60), COOKIEPATH, COOKIE_DOMAIN );
header( "refresh:0; url=http://mywebsite.com" );
}