Web Hosting Talk







View Full Version : htpasswd on a directory


Atif Munir
08-24-2002, 12:38 AM
Hi,
I am creating a passwd on a directoy with the help of htpasswd. But its not working and does not prompt for passwd.The .htaccess I have created is a under.
------------------------.htaccess------------------------------------------
AuthUserFile /var/www/html/.htpasswd
AuthName Admins
AuthType Basic
<Limit GET>
require valid-user
</Limit>
------------------------------------------------------------------------------
Then I use
#htpasswd -c /var/ww/html/.htpasswd atif

In this way passwd file is also created by still it does not ask for passwd and goes directly into the index.html.

Thanks in advance.
Atif

bitserve
08-24-2002, 02:28 PM
Maybe you need AllowOverride in your httpd.conf for that dir?

Studio64
08-24-2002, 06:06 PM
Simple quick .htaccess file that I know to work

AuthType Basic
AuthName "Secure Pages"
AuthUserFile /var/www/html/.htpasswd
require valid-user