setcookie undocumented feature

From: Date: Fri, 27 Sep 2002 12:54:57 +0000
Subject: setcookie undocumented feature
Groups: php.doc 
Request: Send a blank email to phpdoc+get-969348848@lists.php.net to get a copy of this message
Hi, When I was doing some security tests, I walked into some small problems, and did some tests with the returned headers. It seemed that if I used the setcookie function with a value of null, the expiration time argument seemed to be ignored. Instead, the value was replaced with the text 'deleted', and the expiration time was set to 26 hours ago. Is this the way the function should behave? I liked the syntax very much this way: function cookie_destroy() { foreach($_COOKIE as $name => $value) { setcookie($name, null, time() - 3600, "/"); } } If this really is a built-in feature, I would very much like to see it back in the PHP documentation. Regards, Edwin van Vliet

« previous php.doc (#969348848) next »