note 79877 deleted from function.setcookie by betz
| From: | betz@php.net | Date: | Mon, 17 Dec 2007 17:41:40 +0000 |
| Subject: | note 79877 deleted from function.setcookie by betz | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-133733@lists.php.net to get a copy of this message | ||
Note Submitter: marcosfac at gmail dot com
----
Hi folks, I have a problem to view my cookie. I create my cookie when a page is loaded, after I
close this page and access another to view this cookie and I can't see that. follow the code
Below:
Cad.php (write a cookie)
---------------------------
if ($primcad > 0)
{
echo "To update".$resultado["userID"];
setcookie("codes" , 1 , time()+3600 * 24 * 5); // 5 days
}
else {"You are not a member"};
---------------------
Now, I wanna see my cookie:
seeck.php (read a cookie)
---------------------------------
if (isset($_COOKIE["codes"]))
{echo "The Cookie's value is: ".$_COOKIE["codes"];}
else {// do nothing }
--------------------------------------
could you please answer for marcosfac@gmailo.com?
thanks for help me dudes!!!