-
September 24th, 2004, 03:55 PM
#21
when you made the htpasswd file with the htpasswd command, you made it htpasswd not .htpasswd right? So I think this will work for you .htaccess file
Code:
AuthType Basic
AuthName "Restricted Files"
AuthUserFile c:/Program Files/Apache Group/Apache2/auth/htpasswd
Require user philman213
and if you made the file .htpasswd you would simply use
Code:
AuthType Basic
AuthName "Restricted Files"
AuthUserFile c:/Program Files/Apache Group/Apache2/auth/.htpasswd
Require user philman213
to see which one you used just open up my computer and navigate to that directory and it will either have a . or not. Hope this finally gets it working.
-
September 24th, 2004, 10:33 PM
#22
Member
I found a error that I made, in .htaccess I directed it to .htpasswd, when it was always htpasswd (without the period). But still, I get the same error. After trying C:/... and C:\... I still get the error. I check my error log and this is what it has to say:
[Fri Sep 24 14:39:11 2004] [alert] [client **.***.***.***] C:/Program Files/Apache Group/Apache2/htdocs/*******/.htaccess: AuthUserFile takes 1-2 arguments, text file containing user IDs and passwords, referer: http://www.*************.com/***********
-
September 24th, 2004, 11:29 PM
#23
Your passwords file does not need to be called .htpasswd, you can call it wibble.txt if you like (but ensure it is not downloadable by the web server).
I normally call it htpasswd or htpasswords and store it outside of the web root. Putting the fullstop in front just makes it hidden in Unix, which is really superfluous.
As ever, check the error log if there is an error - only change one thing at once.
You will need an AuthType directive, and also a Require directive - make sure they're there.
Slarty
-
September 24th, 2004, 11:59 PM
#24
Member
I guess you didnt read or I didnt say but my htaccess is identical to the one on the apache site except I have the feilds correct.
-
September 25th, 2004, 03:05 AM
#25
I think the space in your .htaccess file is screwing it up. I'm thinking it's seeing stuff after the space as a second parameter. Try putting quotes around it. If that doesn't work search around for a solution. Peace.
-
September 25th, 2004, 07:12 AM
#26
Member
I fixed it. Thanks anyway. Apparently I had to add quotes on the C:\ when I was told by many people not too :-O
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|