wannabe_god Posted November 19, 2006 Share Posted November 19, 2006 Hey,For keeping users logged in, i set a cookie with their name and password.Now i made a logof page, but that one doesnt work the way i want him to. <?setcookie("settings","",time()+3600);?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /><? if(!$_GET["ref"])echo("<meta http-equiv=\"refresh\" content=\"1;url=logoff.php?ref=1\" />");elseecho("<meta http-equiv=\"refresh\" content=\"1;url=index.php\" />");?><title>Logoff</title></head><body><? echo($_COOKIE["settings"]."<br />"); ?>Logging out...</body></html> I tried a moment in the past to delete the cookie, but that doesnt work.Now everything works fine in opera, he first shows me the old cookie and then an empty one after the refresh, but in IE it keeps saying that i'm logged in. he just doesn't sets the cookie.edit--wtf... i edit, even remove my logoff.php page, but opera keeps opening an older version of it Link to comment Share on other sites More sharing options...
justsomeguy Posted November 19, 2006 Share Posted November 19, 2006 Both browsers might be caching the page. Try adding these to the page head:<meta http-equiv="Pragma" content="no-cache"><meta http-equiv="Expires" content="-1"> Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now