Peter Lauri wrote:
When you just use time() you tell the cookie to just live until now, so it
dies directly. You have to add some seconds to determine how long the cookie
will live.
/Peter
-----Original Message-----
From: BBC [mailto:bbc_danang@xxxxxxxxxx]
Sent: Saturday, August 12, 2006 7:48 PM
To: PHP
Subject: SETCOOKIE
Hi List,
I want to set the cookie in which that cookie would be deleted automatically
as visitor closes the browser. I have read an article
from www.php.net/manual/en/function.setcookie and it is told me that we can
set that cookie by unset the value time, but it doesn't
work.
Example:
Setcookie($var, $value, time(), $path, $domain, $secure_binary);
time() = without adding.
Any one can tell me the other way ..
Thank in advance.
Best Regards
============BBC============
**o<0>o**
Try replacing time() with simply "" so it is not set.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php