Alright, here's what's going on:
I'm trying to create a login / logout system for a game me and my friends are working on, this is my first PHP project. I'm teaching myself, so I don't have a teacher to ask this to.
Anyways, for the logout system, you click a link to the logout page, logmeout.php, and it will delete the cookie for you. Then you are redirected to the home page. I've seen this successfully implimented before, such as on conquerclub.com.
Here's what I'm at right now:
CODE
<?php
setcookie("account", "", 1);
header( 'Location: http://www.sbboard.com/auslander/home.php ');
?>
I've also tried it with
CODE
setcookie("account", "", time()-36000);
;
CODE
setcookie("account", "", 1, '/');
; and
CODE
setcookie("account", "", time-36000, '/');
.
The weird part is that after the user has manually deleted the first cookie, their computer can seemlessly log in and out, functioning how it's supposed to. I've also confirmed this by checking my cookies --- it's not a cache issue, the cookie simply isn't deleted the first time around
Any insight would be great