Re: [PHP] set_error_handler() fails

2006-05-06 Thread Richard Lynch
On Fri, May 5, 2006 8:08 am, Martin Alterisio \"El Hombre Gris\" wrote: > And set_error_handler() returns NULL because there isn't a previously > defined error handler, not because it failed. Since it's documented to return NULL when it fails to set the error handler, one would hope it does NOT re

Re: [PHP] set_error_handler() fails

2006-05-06 Thread Richard Lynch
On Fri, May 5, 2006 6:20 am, icy wrote: > chris smith wrote: >> >> What does your code look like? > > I just realized that when called a second time, set_error_handler() > returns my custom error handler but it is never triggered. > Code looks like this: > >if (set_error_handler('core_error

Re: [PHP] set_error_handler() fails

2006-05-05 Thread Martin Alterisio \"El Hombre Gris\"
icy escribió: chris smith wrote: What does your code look like? I just realized that when called a second time, set_error_handler() returns my custom error handler but it is never triggered. Code looks like this: '; trigger_error('test error'); var_dump(set_error_handler('core_er

Re: [PHP] set_error_handler() fails

2006-05-05 Thread icy
chris smith wrote: What does your code look like? I just realized that when called a second time, set_error_handler() returns my custom error handler but it is never triggered. Code looks like this: '; trigger_error('test error'); var_dump(set_error_handler('core_error_han

Re: [PHP] set_error_handler() fails

2006-05-05 Thread chris smith
On 5/5/06, icy <[EMAIL PROTECTED]> wrote: Richard Lynch wrote: > It's possible that you have mistaken whatever set_error_handler > returns for "no previous error handler" for NULL... > > Are you using === NULL or is_null() to test? > > If not, I suspect it's really returning FALSE or '' and what

Re: [PHP] set_error_handler() fails

2006-05-05 Thread icy
Richard Lynch wrote: It's possible that you have mistaken whatever set_error_handler returns for "no previous error handler" for NULL... Are you using === NULL or is_null() to test? If not, I suspect it's really returning FALSE or '' and what you think is an error condition is, in fact, not an

Re: [PHP] set_error_handler() fails

2006-05-04 Thread Richard Lynch
On Thu, May 4, 2006 4:19 pm, icy wrote: > I use set_error_handler() in my script but it fails and returns NULL > indicating an error has happened. > But there are no entries in error.log ore something similar. > How can I find out what actually went wrong? It's possible that you have mistaken what

[PHP] set_error_handler() fails

2006-05-04 Thread icy
I use set_error_handler() in my script but it fails and returns NULL indicating an error has happened. But there are no entries in error.log ore something similar. How can I find out what actually went wrong? PS: I use error_reporting(E_ALL) and init_set('display_errors', 'On') on PHP 5.1.3 -