Re: note 15649 added to function.setcookie

From: Date: Tue, 25 Sep 2001 08:15:31 +0000
Subject: Re: note 15649 added to function.setcookie
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-18272@lists.php.net to get a copy of this message
On September 25, 2001 01:15 am, ryan.russell@trinity.edu wrote: > I just spent several hours trying to find out what was causing my > cookies not to be stored correctly. It seems with build php-4.0.3pl1 > you must pass the expiration within quotes. i.e. > setcookie("name", "value", time()+3600) > would not work whereas > setcookie("name", "value", "time()+3600") > does. I'm not sure why the change, as the code worked before the new > version of php was installed... Perhaps it will save someone the > headache I endured. Thank you for the note. However, it will give new users the wrong idea - you are actually passing a string that contains "time()+3600", instead of passing the output of the time function plus 3600 seconds. -- Zak Greant PHP Quality Assurance Team http://qa.php.net/ "We must be the change we wish to see." - M. K. Ghandi

« previous php.notes (#18272) next »