Richard Peacock wrote:
*From:* Andrew Hole [mailto:andremailinglist@xxxxxxxxx] *Sent:* 26 August 2009 12:24 *To:* users@xxxxxxxxxxxxxxxx *Subject:* Handling 404 errors
Richard, when replying, can you quote normally, and not make your reply look like some malformed signature to the original post? I had no idea this was a reply until I hit "reply" in my mailer.
What I want to know is if there are any option on Apache to handle 404 status code without retry the request. When file not found, some logic will handle the 404 and return the file located on other folder.
ErrorDocument. That can be a script, or might even be handled within httpd.conf with mod_rewrite.
ErrorDocument 404 /errordocs/404error.php
Yes, that's an option.
<html><META http-equiv=’refresh’ content=’1;URL=http://www.example.com/core/$_SERVER["REQUEST_URI"]’;></html>
But that is not. It's very, very evil, and damages end-users. Your PHP (if that is your choice of scripting language) needs to return the document you want to send. -- Nick Kew --------------------------------------------------------------------- The official User-To-User support forum of the Apache HTTP Server Project. See <URL:http://httpd.apache.org/userslist.html> for more info. To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx " from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx