php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #54548 needed a way to define multiple error handlers
Submitted: 2011-04-16 20:15 UTC Modified: -
Votes:2
Avg. Score:5.0 ± 0.0
Reproduced:2 of 2 (100.0%)
Same Version:0 (0.0%)
Same OS:1 (50.0%)
From: giorgio dot liscio at email dot it Assigned:
Status: Open Package: Scripting Engine problem
PHP Version: 5.3.6 OS: all
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: giorgio dot liscio at email dot it
New email:
PHP Version: OS:

 

 [2011-04-16 20:15 UTC] giorgio dot liscio at email dot it
Description:
------------
hi, since a lot of [debug]frameworks/libs relies on set_error_handler would be nice to have a way to provide a stack of error handlers (like spl autoload stack, ticks etc)

register_error_handler($callback, /* prepend */ TRUE | FALSE)
and 
unregister_error_handler


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2011-07-19 12:06 UTC] alex dot schuch at gmx dot de
I have encountered the very same problem.

set_error_handler() returns the previously installed error handler, so maybe it can be called using call_user_func() somehow. The example (PHP manual) of set_error_handler() actually stores the previously installed error handler but does not use it.
 
PHP Copyright © 2001-2020 The PHP Group
All rights reserved.
Last updated: Sat Feb 29 10:01:27 2020 UTC