note 27710 deleted from function.setcookie by philip
| From: | philip@php.net | Date: | Tue, 21 Jan 2003 21:44:19 +0000 |
| Subject: | note 27710 deleted from function.setcookie by philip | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-42544@lists.php.net to get a copy of this message | ||
As documentation says, "Cookies will not become visible until the next loading of a page that
the cookie should be visible for."
The easiest way to see cookies within the same loading of page:
setcookie('mycookie', 'foobar');
$_COOKIE['mycookie'] = 'foobar';
// ...
Of course, assigning a value to $_COOKIE won't change the value of the cookie on the
user's system.