Functions: Update to view_array() function.
This commit is contained in:
@@ -1945,8 +1945,14 @@ function number_pad($number,$n) {
|
|||||||
|
|
||||||
//output pre-formatted array keys and values
|
//output pre-formatted array keys and values
|
||||||
if (!function_exists('view_array')) {
|
if (!function_exists('view_array')) {
|
||||||
function view_array($array, $exit = true) {
|
function view_array($array, $exit = true, $return = false) {
|
||||||
echo "<br><pre style='text-align: left;'>".print_r($array, true).'</pre><br>';
|
$html = "<br><pre style='text-align: left;'>".print_r($array, true).'</pre><br>';
|
||||||
|
if ($return) {
|
||||||
|
return $html;
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
echo $html;
|
||||||
|
}
|
||||||
$exit and exit();
|
$exit and exit();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user