.htaccess拒绝某些IP的某些文件访问

时间:2013-03-30 16:55:36

标签: file .htaccess ip

我必须拒绝在服务器上访问特定IP范围的三个php文件,我应该选择哪种方式?这些例子是否正确?

<FilesMatch "\register.php|\login.php|\admincp\index.php|\modcp\index.php">
order allow,deny
allow from all
deny from x.x.x.x
</FilesMatch>

<Files "\register.php|\login.php|\admincp\index.php|\modcp\index.php">
order allow,deny
allow from all
deny from x.x.x.x
</Files>

Thanx寻求帮助

0 个答案:

没有答案
相关问题