I'm setting up basic http authentication for my dev site with .htaccess
and .htpasswd
.
First, I created my .htpasswd
user and password (https://shop.alterlinks.com/htpasswd/htpasswd.php MD5).
Then, my htaccess file with some basic configurations.
I placed both my .htaccess
and .htpasswd
files in my php_site_project
folder (I know it's not safe, but I did it for testing first the authentication).
Also in my apache configuration file, I have AllowOverride All
AuthuserFile /home/my_user/public_html/php_site_project/.htpasswd
AuthName "Protected Area"
AuthType Basic
AuthGroupFile /dev/null
Require user admin
After all those configurations, I cleared my cache and tested on Chrome, it keeps asking me for user and password over and over... On Firefox asks just once but doesn't let me enter either.
By the way, I don't have logs on this problem.