I am trying to make a conditional PHP debugger tool, that, when called, will write certain steps in execution like a position in code which corresponds to a function or level.
I formed it as:
define("DEBUGGING", TRUE); //IF TRUE, TURNS ON CONDITIONAL CODE THAT RETURNS CODE FLOW
and
if (DEBUGGING) { echo "RETURN LINE OF CODE OR SOMETHING ELSE"; }
which I insert where needed.
Is there a better way to do this? I did turn all PHP warning levels ON, but that is not enough as I don't know which part of the code was executed due to redundant functions.
Thanks!
