note 103734 deleted from function.print-r by danbrown
| From: | danbrown@php.net | Date: | Sat, 30 Apr 2011 16:29:21 +0000 |
| Subject: | note 103734 deleted from function.print-r by danbrown | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-179313@lists.php.net to get a copy of this message | ||
Note Submitter: a dot furmanov at i-ween dot com
----
Sometimes we want to show only few levels of array/object or disable to show several
branches of array (for example, when we have recursive links in array), and print_r()
doesn't allow us to do this.
I wrote method
function print_a($arr, $return = false, $depth = null, $excludeFilter=array())
that can:
.....
have no chances to insert snippet there by "Your note contains a bit of text that will result
in a line that is too long, even after using wordwrap()." stupid error, so you can get code
there:
http://i-ween.com/samples/print_a.php.txt
(if moderators can add this code there - just do it)