Submitted by mindpiss on Fri, 25/01/2013 - 10:25
Let's say you see recurring error messages in your db log file and you want to try and pinpoint the issue to be able to apply a fix.
So, how do you go about debugging your code?
Well, there are many different ways. You could go old-school and use
var_dump();
or
print_r();
.
Or you could go a step further and use
debug_backtrace();
to try and pinpoint the source of the error.