This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Print out a stack trace from entry point to wherever this function was called. | |
* @param boolean $show_args Show arguments passed to functions? Default False. | |
* @param boolean $for_web Format text for web? Default True. | |
* @param boolean $return Return result instead of printing it? Default False. | |
*/ | |
public static function stack_trace($show_args=false, $for_web=true, $return=false){ | |
if ($for_web){ | |
$before = '<b>'; | |
$after = '</b>'; |