I'm trying to set up a protected directory on my Linux server that is running Apache.
I'm following the instructions that my host has given me. Setting it up using Plesk control panel, doesn't work, so I'm doing it via SSH.
I'm generating a .htpasswd file in directory
Then I'm creating a .htaccess file in directory that I want to protect and pointing it to .htpasswd file. Here are contents of my .htaccess file
AuthUserFile /var/www/vhosts/mysite.com/.htpasswd AuthGroupFile /dev/null AuthName "Authentication Pop Up" AuthType Basic <LIMIT POST GET> require user username </LIMIT>
Now when I browse to that directory I get a prompt to log in. However, I can't log in with username/password that I have created. My guess is that .htaccess file is not finding the .htacess file. But I'm not sure, there are no errors.