I tryed to email me debug_backtrace()
but it just prints out the array.
I need to assign it to a variable so that var_export can work with it.
How can i do that?
views:
53answers:
5
+1
A:
debug_backtrace
returns the array, but doesn't print it. There's probably something wrong with the code that handles the emailing of the report. Could you paste that piece of code here as well?
WordPress Hardcore
2010-04-13 10:28:06
+1
A:
Send the following $msg :
$msg=print_r(debug_backtrace(),true));
Not tested, but that's one way.
zaf
2010-04-13 10:35:50
+1
A:
There is a function that "prints out the array", debug_print_backtrace
. You didn't mix those two up by any chance?
And both var_export() and print_r() by default print the result. You have to pass true
as the second parameter if you want them to return the result (so you can assign it to a variable)
$result = var_export(debug_backtrace(), true);
VolkerK
2010-04-13 11:01:00