Quantcast
Channel: My Science Is Better » Apache
Viewing all articles
Browse latest Browse all 2

Password protect a folder in Apache using .htaccess

0
0
mkdir -p /home/secure/
htpasswd -c /home/secure/apasswords developer
chown apache:apache /home/secure/apasswords
chmod 0660 /home/secure/apasswords

then in your htaccess add these:

AuthType Basic
AuthName "Restricted Access"
AuthUserFile /home/secure/apasswords
Require user developer

Viewing all articles
Browse latest Browse all 2

Latest Images

Trending Articles





Latest Images