[PHP] RE: Error trapping, on scripts that don't exist

2001-09-05 Thread Tim Ward
thanks to Mahmoud for trying to help, but the php error trapping functions rely on the engine being able to auto-prepend the error trapping script. I tried a solution like this ... ?php if (!file_exists($PATH_TRANSLATED)) { include($DOCUMENT_ROOT/error.html);

[PHP] Re: Error trapping, on scripts that don't exist

2001-09-05 Thread Moody
This is how it works (in very crude not-even-pseudo code, but I'm sure you'll be able to follow the logic!): BEGIN 1. Browser requests a resource (file) from your web server. 2. Web server checks to see whether requested resource exists. 3. if (!2) web server generates 404 error (page does not

[PHP] Re: Error trapping

2001-09-03 Thread Moody
Try writing a custom error handler. Chech out http://www.zend.com/zend/spotlight/error.php for a good article on the subject. Pay particular attention to the bit at the end about output buffering since I assume that what you would want to do is send a redirect header to the browser if the script

[PHP] Re: error trapping

2001-07-26 Thread Yasuo Ohgaki
TRY / CATCH is not implemented for PHP. (yet. Next major version up probably) I suggest to make custom error handler and use trigger error for now. -- Yasuo Ohgaki Phil Spitler [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... I am wondering the best way to handle