http://www.perlmonks.org?node_id=1002673


in reply to Re^2: How to identify if URL is mod_perl handler
in thread How to identify if URL is mod_perl handler

vcTheGuru:

Gah! I hate it when people "help" me like that. It breaks the model of the web. If a page doesn't exist, I want to know about it--but the "I" in question is one of my scripts, not me personally. If I get a 404, then I can recognize the condition and continue. My scripts, however, aren't clever enough to do so. If instead someone "helpfully" redirects me to something else, then I can't reliably detect the condition. (My home ISP does that to me, and it gripes me to no end.)

If you're going to do something like that, I'd suggest making a 404 page that gives you the index page of the directory, instead. That way, it can be detected more easily, *and* allow people to find what they're looking for.

</rant>

Update: Having said that, getting the 301 or 302 code would be fine, too. Anything's better than some odd page with a 2xx status code.

Update: Added sentence starting "My scripts"

...roboticus

When your only tool is a hammer, all problems look like your thumb.