View Single Post
Old 2010-09-14, 09:36 AM   #19
Cleo
Subversive filth of the hedonistic decadent West
 
Cleo's Avatar
 
Join Date: Mar 2003
Location: Southeast Florida
Posts: 27,936
Quote:
Originally Posted by LD View Post
Do have the code for that?
To password protect a directory.

First go here and encrypt a userID/password.
http://www.e2.u-net.com/htaccess/make.htm

In a directory someplace on your server create a file named.
Code:
.htpasswd
Copy and paste your encrypted userID/password into this file

Now in the directory that you want to protect create a file named
Code:
.htaccess
Place this text in the file changing the path to your actually path.
Code:
AuthUserFile /path/to/your/password/file/.htpasswd

AuthGroupFile /dev/null
AuthName "Whatever You Want The Password Dialog To Be Called"
AuthType Basic
<Limit GET POST>
order allow,deny
allow from all
require valid-user
</Limit>
Enjoy your much safer admin.
__________________
Free Rides on Uber and Lyft
Uber Car: uberTzTerri
Lyft Car: TZ896289
Cleo is offline   Reply With Quote