Header("WWW-Authenticate: Basic realm='$SERVER_NAME' "); Header("HTTP/1.0 401 Unauthorized");
is the proper http auth hearders, change the realm and you'll have to re-authenticate. -- Chris Lee [EMAIL PROTECTED] "J.F.Kishor" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > hello all, > > I have designed a web page using php, as a security measure I have > kept it password protected. I have used Apache authentication, using > htpasswd file. Now I want to keep a logout in this web page, I tried to > send a header request "http/1.0 401 Unauthorized" to force it to > reauthenticate when the logout link is clicked in the form, but this dose > not work. > > I tried using session_destroy() even that does not work. > > To get the authenticated users name I have used GetEnv("REMOTE_USER") in > all the form and with that username I'am handling mysql and other requests. > I don't know where exactly the REMOTE_USER gets stored. > > So please help me out in this problem. I want to remove the > window's authentication cache. > > Please give me some ideas and suggestion to remove the user name and make > the page fresh for the other user to log in. > > If possible please send me a sample script. > > > > > kishor > Nilgiri Networks > > > > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]