Go Back   CodingForums.com > :: Server side development > Apache configuration

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 10-01-2003, 09:58 PM   PM User | #1
sesme
New to the CF scene

 
Join Date: Oct 2003
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
sesme is an unknown quantity at this point
htaccess: trying to serve different pages

Hi,
I'm new to htaccess and my isp is not helping.
What I'm trying to do is serve a page called "block.htm" to the ip's and domains that I have listed as "deny."

I'm not sure if they see it or not. i do know the way it is now the "block" page gets pushed to any 403/404 error. so anybody that types a wrong address gets it.

So, i want ONLY those being denied to get the block.htm file and everyone else to get normal 403/404.

THANKS for all help

here is what i have now:
<Limit GET>
order allow,deny
allow from all
deny from .xxx.net
</Limit>

ErrorDocument 403 http://www.xxxxx.com/block.htm

ErrorDocument 404 http://www.xxxxx.com/block.htm

deny from 192.167.44.33
sesme is offline   Reply With Quote
Old 10-13-2003, 05:02 AM   PM User | #2
firepages
Super Moderator


 
Join Date: May 2002
Location: Perth Australia
Posts: 3,942
Thanks: 7
Thanked 82 Times in 81 Posts
firepages will become famous soon enough
403 and 404 documents do different things ,

404's are served when a page can not be found
403's are served when permission is denied denied

so try serving different pages for different situations ... eg

ErrorDocument 403 /path/block.htm
ErrorDocument 404 /path/custom_404.htm
__________________
resistance is...

MVC is the current buzz in web application architectures. It comes from event-driven desktop application design and doesn't fit into web application design very well. But luckily nobody really knows what MVC means, so we can call our presentation layer separation mechanism MVC and move on. (Rasmus Lerdorf)
firepages is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 04:07 AM.


Advertisement
Log in to turn off these ads.