DR.Wong
01-08-2007, 09:09 AM
Hey everyone..
I am trying to set a cookie so that a user does not have to enter their name into a text field every time they submit a comment...
I have a check box on the submission page and check for its value on the proccessing page like this :
if ($remember) { setcookie('rantname','$name', mktime()+86400, '/'); }
$remember is the variable that I grab from the post of the check box, I know it is working cus I tested that if statement with a text echo, but I am getting the following error (on that line of code) :
Warning: Cannot modify header information - headers already sent by (output started at /hsphere/local/home/nicholas/braddanick.com/head.php:7)
head.php is an included php page that contains my menu..
can anyone give me a hand?
I am trying to set a cookie so that a user does not have to enter their name into a text field every time they submit a comment...
I have a check box on the submission page and check for its value on the proccessing page like this :
if ($remember) { setcookie('rantname','$name', mktime()+86400, '/'); }
$remember is the variable that I grab from the post of the check box, I know it is working cus I tested that if statement with a text echo, but I am getting the following error (on that line of code) :
Warning: Cannot modify header information - headers already sent by (output started at /hsphere/local/home/nicholas/braddanick.com/head.php:7)
head.php is an included php page that contains my menu..
can anyone give me a hand?