Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

.thaccess only prompting user password only once

Status
Not open for further replies.

keak

Programmer
Sep 12, 2005
247
CA
HI there,
I am trying to create a .htpasswd structure.
In my htaccess I have
Code:
AuthName "Members Only"
AuthType Basic
AuthUserFile /[URL unfurl="true"]www/www.site.com/.htpasswd[/URL]
AuthGroupFile /dev/null

ErrorDocument 404 /error.html
ErrorDocument 403 /error.html
ErrorDocument 401 /error.html
Options -Indexes
require valid-user

When i log in with the right password, i can hit the member area correctly.
However, when I enter a wrong password, instead of prompting me again, it goes to a page cannot be displayed.

My other sites prompts me 3 times if a worng passowrd is entered and then the "Authorization Required" so I am kind of lost what I am doing wrong here.


Any input is much appreciated! :)
 
Get rid of the 401 ErrorDocument. If you use the wrong password, the server will return a 401 & therefore take you to /error.html (which I assume is not there - 'page can not be displayed')
 
Hi there,
I tried that and its still giving me the password prompt only one time and going to a page not found.
The error document is there, and when I hit after logging in, I can access that page fine.

It's been a real werid problem for us and we are kind of running out of ideas here lol ... thank thanks for that input
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top