😕
I'm trying to set a cookie in the following way:
Website visitor visits my site http://www.mysite.com/?nic=221
I want to set a cookie called "id" to the value of nic in the url (in this case 221) so long as nic is equal to or greater than 1, so my code is the following:
<?php
if ($nic >= 1)
{
setcookie( "id", "$nic", time ()+31536000, "/",
"mysite.com", 0 );
}
?>
Now the above works fine in i.e. 4.x and above, opera, mozzila etc but it won't set the cookie in Netscape 4.x or Netscape 6.x
I've read the netscape spcification for setcookie function but I can't see what I'm doing wrong. Are there any known issues or does someone see an error in my code?
I've been staring at this for nearly three hours now!
Thanks for your help!
Gavin