Hello and welcome to our community! Is this your first visit?
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New to the CF scene
    Join Date
    Oct 2003
    Thanked 0 Times in 0 Posts

    htaccess: trying to serve different pages

    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

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

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

    deny from

  2. #2
    Super Moderator
    Join Date
    May 2002
    Perth Australia
    Thanked 110 Times in 108 Posts
    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)


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts