This file contains hidden or 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
<?php | |
/** | |
* $data mixed - will accept strings or arrays - the data to be cleaned | |
* $key mixed - will accept strings or arrays - if passed in, the array_walk will only clean those fields | |
* | |
*/ | |
function remove_non_utf8_characters( $data, $key = null ) | |
{ | |
// from http://magp.ie/2011/01/06/remove-non-utf8-characters-from-string-with-php/ |
This file contains hidden or 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
/** | |
* a simpler version of debug_backtrace() | |
* | |
* @param boolean $show_args Pass true to display argument values in the output | |
* @param boolean $expand_objects when $show_args == true, pass true to expand object values, default to false to avoid over-verbosity | |
* | |
*/ | |
function simple_backtrace( $show_args = false, $expand_objects = false ) | |
{ | |
$tracers = debug_backtrace(); |