RE: [PHP] Cookie Expiry Dates?
| From: | Adrian Ciutureanu | Date: | Wed, 11 Jul 2001 12:56:35 +0000 |
| Subject: | RE: [PHP] Cookie Expiry Dates? | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-57361@lists.php.net to get a copy of this message | ||
int setcookie (string name [, string value [, int expire [, string path
[, string domain [, int secure]]]]])
expire = time() + 3600*24*30;
Note that 'expire' is the client relative to GMT time. So, if the client
has the local time set to 01/01/1985, your cookie will be born dead ;)
> -----Original Message-----
> From: Jeff Lewis [mailto:jeff@hyrum.net]
> Sent: 11 iulie 2001 15:54
> To: php-general@lists.php.net
> Subject: [PHP] Cookie Expiry Dates?
>
>
> I'd like to set a cookie that never expires or at least one
> that lasts a month, how can I set it? Does it have to be with time?
>
> I am using SetCookie.
>
> Jeff
>