Log out
Date: 08/25/04
(PHP Development) Keywords: web
Hi all.
This is probably a dead simple problem, as I'm sure just about every 's3kr3t' website does it.
I'm trying to make a "members only" part of my web site. I use HTTP Basic Authentication to get a username and password and store that in a session. The problem I've got is when it comes to log out. In my log out script, I unregister the username, password etc and destroy the session. That's fine, session_is_registered() returns false. But now, if the user clicks "Members Area" they get straight back into the private area.
What I'd like to happen is the user clicks log out and then when they go back to the private area they're asked for their username again.
Any suggestions for how to sort that out?
Source: http://www.livejournal.com/community/php_dev/46985.html