Page 1 of 1

.htaccess block IP

Posted: Fri Oct 12, 2007 9:51 am
by ssand
I think I have this correct, but I haven't used .htaccess much for blocking an IP. (I say I think because at least I can still see my site!).

Could someone verify that I have this defined correctly? And if I need to add more I can just copy the deny line correct?

Here's what I have in my .htaccess file:

Code: Select all

<Files *>
order deny,allow
deny from xxx.xx.xxx.xx
</Files>

# Prevent web browsers or spiders from seeing your .htaccess directives:
<Files .htaccess>
deny from all
</Files>

Thanks. :D

Posted: Fri Oct 12, 2007 9:57 am
by Zoxive

Posted: Sat Oct 13, 2007 12:34 am
by ssand
Thanks.
The Fearful Developer wrote:But I agree with you. I have been guilty of doing this more than once...
:roll:

-