Hi,
I am very new to cookies and php and cannot seem to get them working properly.
I have read many tutorials on it by googling but nothing I do works.
I have tried simple code by just typing:
setcookie('newsletter','True');
But nothing is working for me. I am trying to write a script that decides wether or not to display a popup window telling the user about a newsletter we have.
I don't want this cookie to expire. Any help would be greatly apreciated, below I have include a script I have written.
$CookieValue = $HTTP_COOKIE_VARS['Newsletter'];
if ($CookieValue == '')
{
setcookie('Newsletter','True');
}
if ($CookieValue == '' or $CookieValue == 'True')
{
print "<script langague=javascript>";
print "Window.open('newsletter.html','ToolBox','toolbar=no,status=no,width=480,height=400');";
print "</script>";
}