Re: [PHP] Displaying full array contents

2002-09-26 Thread Justin French
It's a slightly different format, but print_r($array) recursively echo the contents of an array ina readable format? http://php.net/print_r Why reinvent the wheel, unless you need that specific format. HTH Justin on 27/09/02 3:50 AM, Brad Harriger ([EMAIL PROTECTED]) wrote: > I'm trying

Re: [PHP] Displaying full array contents

2002-09-26 Thread Joshua Patterson
: "debbie_dyer" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Thursday, September 26, 2002 1:23 PM Subject: Re: [PHP] Displaying full array contents Easier yes and ok for debug but it doesnt look very nice on a web page does it nor does it help if you want to do so

Re: [PHP] Displaying full array contents

2002-09-26 Thread debbie_dyer
eptember 26, 2002 9:17 PM Subject: Re: [PHP] Displaying full array contents > print_r($array); simply print out the entire array.. > It cant be easier. > > "Debbie_dyer" <[EMAIL PROTECTED]> wrote in message > 01bf01c26598$1d84ec00$0100a8c0@homepc">news:01bf0

Re: [PHP] Displaying full array contents

2002-09-26 Thread Martin W Jørgensen
> > Debbie > > - Original Message - > From: "Brad Harriger" <[EMAIL PROTECTED]> > To: <[EMAIL PROTECTED]> > Sent: Thursday, September 26, 2002 8:46 PM > Subject: Re: [PHP] Displaying full array contents > > > > Debb

Re: [PHP] Displaying full array contents

2002-09-26 Thread debbie_dyer
From: "Brad Harriger" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Thursday, September 26, 2002 8:46 PM Subject: Re: [PHP] Displaying full array contents > Debbie, > > Yes. I could use recursion, but what's really hanging me up is keeping > track

Re: [PHP] Displaying full array contents

2002-09-26 Thread Brad Harriger
Debbie, Yes. I could use recursion, but what's really hanging me up is keeping track of how deep into an array I am. It should be fairly simple, but I seem to be having a brain freeze. Brad Debbie_dyer wrote: > You could use recursion example:- > > function printArray($arr) { > fo

Re: [PHP] Displaying full array contents

2002-09-26 Thread debbie_dyer
You could use recursion example:- function printArray($arr) { for ($i =0; $i < count($arr); $i++) { if (!is_array($arr[$i])) { echo $arr[$i]; } else { printArray($arr[$i]); } } } $arr = array("Orange", "Peach", "Apple"); $arr2 = array("Banana"