Re: Non Expiring Cookie
| From: | Richard Lynch | Date: | Tue, 30 Jan 2001 08:35:50 +0000 |
| Subject: | Re: Non Expiring Cookie | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-37267@lists.php.net to get a copy of this message | ||
> Is this a never expiring cookie, or a "per" session cookie? I want to
> create a never expiring cooky.
>
> SetCookie ("MyNeverExpiringCookie", "This cookie should never expire");
That is a session cookie. It will disappear when the user closes the
browser.
The Cookie spec puts an upper bound on how long you can set the expiration
of a Cookie, I think... And I think it's like 2 years...
You can always update the cookie when somebody visits your site again.
Let's face it, if they haven't come back within 2 years, they really aren't
going to remember any context from your cookie anyway.