Click to See Complete Forum and Search --> : htaccess question


toenailsin
01-30-2009, 10:39 PM
Is there a way to specify certain ip's to circumvent basic htaccess authentication?

I'm wanting it so that if someone from the internet accesses my site, they have to enter a password, but if i access it from localhost, it doesn't.

purg
02-05-2009, 07:53 PM
AuthName "Authorised Users Only."
AuthType Basic
AuthUserFile /.htpasswd
require valid-user
Order deny,allow
Deny from all
Allow from 127.0.0.1
Allow from your.static.ip.addr
Allow from anyone.else.ip.addr
Satisfy Any

toenailsin
02-07-2009, 06:25 PM
wow. that works beautifully. thank you very much