Web Hosting Forum | Lunarpages


*
Welcome, Guest. Please login or register.
Did you miss your activation email?



Login with username, password and session length
July 31, 2010, 09:13:03 PM

Pages: [1]   Go Down
  Print  
Author Topic: Creating a logout page using Basic authentication  (Read 809 times)
gaypo0
Space Explorer
***
Offline Offline

Posts: 9


« on: January 05, 2010, 11:05:45 AM »

Hi, I have password-protected a directory of my site using Basic authentication. Now I am trying to create a logout page, but how do I do this? Here is what I have thus far:

<?php
session_start();
session_unset();

session_destroy();
Header("Location: my site's name);
?>

But this doesn't seem to be working. Any suggestions? Thanks.
Logged
Mamady
Newbie
*
Offline Offline

Posts: 3


WWW
« Reply #1 on: February 03, 2010, 11:29:19 PM »

try using session_write_close() before header()
Logged

Web Development and SEO services from Virvo
scanman20
Master Jedi
*****
Offline Offline

Posts: 1448



WWW
« Reply #2 on: February 04, 2010, 06:16:59 AM »

You asked this twice and I already answered you.

http://www.lunarforums.com/web_site_management/creating_a_logout_pagehelp-t54382.0.html;msg358876#msg358876
Logged

Even a broken clock is right twice a day.
NotOneBit.com
MCSE - MCSA - MCP
Pages: [1]   Go Up
  Print  
 
Jump to: