Forum Moderators: coopster

Message Too Old, No Replies

Cookie Problems

setcookie not working in IE6

         

software ted

10:35 am on Feb 27, 2005 (gmt 0)



IE 6 is not displaying the cookie set in the code below but mozilla firefox is just working fine. I have changed the settings to allow all cookies in the internet options for IE6 but still its not working. When i view the files to view the cookie in the option i can see the page...what could be the problem with my IE? on other machines its opening without any problems. Its just my IE...

<?php
// echo "test ftp";
//phpinfo();
setcookie("testCookie","Testing again", time()+3600);
$tmpdata = $_COOKIE["testCookie"];

echo "Your data: $tmpdata";
?>

tata668

1:16 pm on Feb 27, 2005 (gmt 0)

10+ Year Member



I'm not sure if this is your problem but maybe it will help:
[sitepoint.com...]

tata668

1:19 pm on Feb 27, 2005 (gmt 0)

10+ Year Member



Oh, by the way.. I look at your code and I think it is normal that the cookie is not present in $_COOKIE just after setcookie(). It will be there when the next page will be loaded.