|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2004-09-26 04:24 UTC] aidan@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Thu Nov 20 20:00:02 2025 UTC |
Description: ------------ I was attempting to set a cookie using a boolean. TRUE works correctly as 1 but setting it FALSE would not save a cookie at all. Reproduce code: --------------- setcookie("name",FALSE,time()+60*60); if you print_r($_COOKIE); it won't display name as being in the $_COOKIE array but if you setcookie("name",TRUE,time()+60*60); it lists name == 1 in $_COOKIE Expected result: ---------------- If it's a by design issue it might be a good idea to include this in the docs stating not to use booleans with cookies.