Re: Need an array parser(CONT)
| From: | Steve Edberg | Date: | Wed, 28 Feb 2001 19:58:23 +0000 |
| Subject: | Re: Need an array parser(CONT) | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-42071@lists.php.net to get a copy of this message | ||
At 12:33 PM -0800 2/28/01, Dallas K. wrote:
I am looking for somthing that will parse a multidimentional array of any
size, and return a key / value listing for debugging....
Example:
if I have an array such as...
$arr[name] = dallas
$arr[address][city] = austin
$arr[address][state] = Texas
$arr[somthing][somthing_else][blah1]= some_value1
$arr[somthing][somthing_else][blah2]= some_value2
$arr[somthing][somthing_else][blah3]= some_value3
I would want the result to be displaied as:
ARR
name --- dallas
address --- city --- austin
address --- state --- Texas
somthing --- somthing_else --- blah1 --- some_value1
somthing --- somthing_else --- blah1 --- some_value1
var_dump($arr) or print_r($arr) --- see
http://www.php.net/manual/en/function.var-dump.php
http://www.php.net/manual/en/function.print-r.php
-steve
--
+--- "They've got a cherry pie there, that'll kill ya" ------------------+
| Steve Edberg University of California, Davis |
| sbedberg@ucdavis.edu Computer Consultant |
| http://aesric.ucdavis.edu/ http://pgfsun.ucdavis.edu/ |
+-------------------------------------- FBI Special Agent Dale Cooper ---+