Re: sending a 404 error
| From: | GATop | Date: | Mon, 17 Sep 2001 04:44:02 +0000 |
| Subject: | Re: sending a 404 error | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-67514@lists.php.net to get a copy of this message | ||
Hello Michael,
Sunday, September 16, 2001, 9:05:35 AM, you wrote:
MAP> Is it possible to invoke the server 404 error error from php?
MAP> Where I would like to do such a thing is
MAP> http://24.5.29.77:10080/encryption/index.phps
MAP> I would like to replace the line
MAP> die ("The file you wish to download does not exist");
MAP> with instead an invocation of the http 404 error.
MAP> Theoretically a 404 error should never happen if I properly did my stuff, but it would be
MAP> nice for me to be able to detect such problems just from the http error logs...
MAP> If there's not a way to directly do it, I'll need to redirect to a 404 error page
MAP> (well, include my custom error page) and have the script make an entry into the http_error log- but
MAP> a nice one
MAP> liner invocation of Apache's built in 404 error function would be nice...
Yes You can
header ("404 Not Found");
should work
--
Best regards,
GATop mailto:gatop@hot.ee