I\'m working on blocking a folder with .htaccess, which I\'ve never used before, and I\'m having some trouble. Here\'s what I have
.htaccess (located in the folder I
Had the same problem, it had to do with access! Have you given ownership of the password file to www-data
user through
chown www-data /var/www/.htpasswd
chmod 640 /var/www/.htpasswd
? It's best to keep the password, for obvious reasons, to keep the password somewhere outside the /var/www/
directory, let's say /home/MYSERVER/
in such a case you also need to give ownership of this parent directory to the user www-data
.