2012-06-01 55 views
1
ErrorDocument 500 /errors/notfound.html 
ErrorDocument 404 /errors/notfound.html 
ErrorDocument 403 /errors/notfound.html 

Options +FollowSymLinks 

<IfModule mod_rewrite.c> 
RewriteEngine On 
RewriteBase/
RewriteCond %{HTTP_REFERER} !^$ 
RewriteCond %{HTTP_REFERER} !^http://(www\.)?operationtoad.com/.*$ [NC] 
RewriteRule \.(rar|exe|zip|html)$ - [F] 
</IfModule> 

order deny,allow 
deny from all 
allow from ##.###.###.## 

當我添加第二個或第三人的第二從線允許,他們可以看到的主要場所,但他們無法去到/notfound.html或/anonexistingfile.html - 他們將看到apache啓動頁面或他們得到500錯誤。我不能讓我的所有否定我的.htaccess的工作給大家

現在,如果我從我這裏刪除自己,我只是在根上獲得apache測試頁,在其他人上禁止403測試頁。

回答

0

不是真的答案,但... 而不是允許IP,您可以用htpassword替換它。

並仔細檢查你的RewriteRule條件,可能是它裏面的一個bug。