Hi, thanks a lot for taking the time to try to help me out.
The thing is, the POST operation from the sign in form works... as I can verify by looking at my cookie.txt file.
It's only when I try to expire or delete the cookie that the operation fails.
The sign in form posts $user and $pass to signin.php3 which immediately calls
<?php
if (!($user==""))
{
setcookie ("EEUID", $user, 0, "/", "www.employersemail.com", 0);
}
if (!($pass==""))
{
setcookie ("EEPWD", $pass, 0, "/", "www.employersemail.com", 0);
}
?>
which works, as verified by special cookie generated tags on the other pages and by looking at my cookie file (see http://www.employersemail.com to see the exact pages in question, if you wish). It expires correctly when I shut the browser window, as well.
However, when the user tries to log out, he/she will be sent to signout.php3, which immediately calls:
<?php
setcookie("EEUID", "RESET" , time()-1000000 , "/", "www.employersemail.com", 0);
setcookie("EEPWD", "RESET" , time()-1000000 , "/", "www.employersemail.com", 0);
//setcookie("EEUID");
//setcookie("EEPWD");
//I also tried ten thousand other things
?>
but the "special cookie generated tags" are still visible on the pages, and the cookie is not updated in my cookie.txt file.
The cookie FAQ at http://www.cookiecentral.com/faq/#6.2 clearly states that:
"The two main steps to clearing a cookie you have created are:
1.Set the cookie's value to null.
2.Set the cookie's expiration date to some time in the past."
and furthermore that
"The reason you must do both is that simply setting the expiration to a past time will not change it's value until the browser is closed. That is, all cookie names, values, expirations, etc are resolved once the browser program has been closed. Setting the cookie to null allows you to properly test for the cookie until that resolution. "
Now, I believe I am attempting to call this header correctly with my code, but obviously I am not.
Thank you very much for your help... any other ideas?