note 15649 added to function.setcookie

From: Date: Tue, 25 Sep 2001 07:15:12 +0000
Subject: note 15649 added to function.setcookie
Groups: php.notes 
Request: Send a blank email to php-notes+get-18268@lists.php.net to get a copy of this message
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. -- http://www.php.net/manual/en/function.setcookie.php http://master.php.net/manage/user-notes.php?action=edit+15649 http://master.php.net/manage/user-notes.php?action=delete+15649 http://master.php.net/manage/user-notes.php?action=reject+15649

« previous php.notes (#18268) next »