And since we have our own handling, couldn't we just have a debug_backtrace() sitting in there, and perhaps an extra mode on the error handling settings that lets errors or warnings do a backtrace? David Strauss wrote:
Doug Green wrote:
The way I track these down is using xdebug2. There's a function called xdebug_get_function_stack that prints the function stack. Edit bootstrap.inc and put this code at the top of check_plain (the function that's really getting the error), it will print the function stack out when you would get the error:
if (is_array($text)) { print_r(xdebug_get_function_stack()); }
Of course, it means that you have to get xdebug installed and working, and this might take a bit of an effort.
You don't need xdebug to print a backtrace in PHP:
debug_backtrace()