Community Forums
Connect with us on LinkedIn
Community Notice
+ Reply to Thread
Results 1 to 4 of 4
  1. #1
    Member
    Join Date
    Aug 2004
    Location
    Atlanta, GA
    Posts
    15

    Default Password Protected Dir Logout

    Iam just starting out. I created a password directory, How do I implement a logout?
    Thanks

  2. #2
    Member bamasbest's Avatar
    Join Date
    Jan 2004
    Posts
    531

    Default

    Re you using .htaccess or another solution for protecting your directory(ies)?

  3. #3
    Member
    Join Date
    Aug 2004
    Location
    Atlanta, GA
    Posts
    15

    Default

    I used the "web protect" function from cpanel. I see an .htaccess file. I just started out, is there a better way?
    Thanks

  4. #4
    Member bamasbest's Avatar
    Join Date
    Jan 2004
    Posts
    531

    Default

    The web protect/.htaccess feature is quite secure.

    However, once a browser authenticates, that browser can visit any number of sites and return to the authenticated site without having to re-authenticate, so long as it has not been closed.

    So, a logout would require closing the browser.

    A snippet of javascript like the following could work for most visitors.

    Code:
    <form>
    <input type=button onClick='window.opener=self;window.close()' value='Logout'>
    </form>

Similar Threads & Tags
Similar threads

  1. password protected dirs ask for password several times
    By mumbles27 in forum cPanel and WHM Discussions
    Replies: 8
    Last Post: 06-21-2009, 05:48 PM
  2. password protected sub-dir, but root dir prompt for password
    By phytonet in forum cPanel and WHM Discussions
    Replies: 3
    Last Post: 01-30-2005, 01:21 PM
  3. PW Protected DIR asking for login twice...
    By boutwell in forum cPanel and WHM Discussions
    Replies: 3
    Last Post: 01-27-2005, 11:13 AM
  4. password protected dir
    By radroni in forum cPanel and WHM Discussions
    Replies: 0
    Last Post: 06-11-2004, 06:48 PM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube