Zubrag.com
October 20, 2019, 02:15:34 PM *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: Some viewers have to login twice  (Read 6242 times)
CapnKirkman
Newbie
*
Posts: 4


« on: March 16, 2009, 06:49:19 PM »

I've got Advanced Password Protection script set up on a site and it works from Mac Safari 3.2.1, and in some cases from various Windows systems using IE, but sometimes on IE you need to log in twice to obtain access to the protected page. I've modified the login page to be index.php, and modified the header, footer and login php files. Let me know if I should paste them here, or if someone knows a common reason why this would require double logins to work.

I've got the automatic logout set on all links to the home page.

Anyone know why this happens?

Logged
CapnKirkman
Newbie
*
Posts: 4


« Reply #1 on: March 20, 2009, 05:57:34 PM »

What should I include in this question to get some response to it? I don't know if this is a very simple solution, or if I'm way off base. I've adapted the login.php to become index.php, and also modified the includes, thus having the login on the home page.

To restate the problems, I have (2) issues I need to resolve:

1) Most viewers need to login twice to get into the protected pages.

2) After successful login, viewers returning to the login page get a blank screen.

In an attempt at resolving issue #2 I added ?logout=1 at the end of all links to the home page, but that didn't seem to resolve the issue.

Let me know if posting the entire php scripts would be helpful, or what. I've put way too many hours into trying to track this down, and it's eating up too much energy. Help!
Logged
eberdome
Newbie
*
Posts: 8


« Reply #2 on: May 07, 2009, 06:58:44 PM »

CapnKirkman,

i cant help with your first issue because im having the same trouble.

as for the second, go into your password_protect.php page, close to the bottom of the page you'll see this:

    // set cookie if password was validated
    setcookie("verify", md5($login.'%'.$pass), $timeout, '/');


DELETE THAT....if you want the logger to be automatically logged out once he or she navigates away from the page!

Reminder: Make sure you close the page and reopen it to refresh cookies! It should work!

Does this help?
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by SMF 1.1.11 | SMF © 2006-2009, Simple Machines LLC