Allow only certain IP on your site

francis

Administrator
Staff member
Put this in your .htaccess to block everybody except some ip:

Deny from All
Allow from xx.xx.xx.xx
Allow from xx.xx.xx.xx

The same thing apply if you want to restrict the access to a file:

<Files admin.php>
Order Deny,Allow
Deny from all
Allow from xx.xx.xx.xx
Allow from xx.xx.xx.xx
</Files>
 
Top