RE: [PHP] Referencing Multi Dimensional Arrays

2004-12-02 Thread Ford, Mike
To view the terms under which this email is distributed, please go to http://disclaimer.leedsmet.ac.uk/email.htm On 01 December 2004 17:31, Robinson, Matthew wrote: I have a search function: $search_result = multi_array_search($net_array,needle); now search_result equals an array of

RE: [PHP] Referencing Multi Dimensional Arrays

2004-12-02 Thread Ford, Mike
To view the terms under which this email is distributed, please go to http://disclaimer.leedsmet.ac.uk/email.htm On 02 December 2004 15:17, Robinson, Matthew wrote: Thanks for the help Mike, If I've got a reference to an entry and say, wanted to insert another entry, can I use

[PHP] Referencing Multi Dimensional Arrays

2004-12-01 Thread Robinson, Matthew
Hi, I've kind of solved this question already using recursion but I recon (in the grand tradition) that someone has a better solution! I have an multi dimensional array that is of variable depth, a snippet is shown below. The problem is that I don't know how deep the array goes as any

Re: [PHP] Referencing Multi Dimensional Arrays

2004-12-01 Thread Jason Wong
On Thursday 02 December 2004 01:14, Robinson, Matthew wrote: I've kind of solved this question already using recursion but I recon (in the grand tradition) that someone has a better solution! I have an multi dimensional array that is of variable depth, a snippet is shown below. The problem

Re: [PHP] Referencing Multi Dimensional Arrays

2004-12-01 Thread Greg Donald
On Wed, 1 Dec 2004 17:14:56 -, Robinson, Matthew [EMAIL PROTECTED] wrote: I've kind of solved this question already using recursion but I recon (in the grand tradition) that someone has a better solution! Recursion and is_array() is the way I'd parse through it. -- Greg Donald

RE: [PHP] Referencing Multi Dimensional Arrays

2004-12-01 Thread Robinson, Matthew
] but you don't know how deep you're going until the search returns you the keys. Hope that clears things a bit! Kind regards Matthew -Original Message- From: Jason Wong [mailto:[EMAIL PROTECTED] Sent: 01 December 2004 17:23 To: [EMAIL PROTECTED] Subject: Re: [PHP] Referencing Multi

Re: [PHP] Referencing Multi Dimensional Arrays

2004-12-01 Thread Jason Wong
On Thursday 02 December 2004 01:31, Robinson, Matthew wrote: lol, perhaps embedded a bit too deep in my pre-amble. My question is simply what's a good way to reference a given array entry when you don't know where it is or how deep the array is. I can do a multi dimensional array search and

Re: [PHP] Referencing Multi Dimensional Arrays

2004-12-01 Thread Richard Lynch
Robinson, Matthew wrote: I've kind of solved this question already using recursion but I recon (in the grand tradition) that someone has a better solution! Recursion and http://php.net/is_array is probably the most clear-cut solution. If you are concerned that the arrays could become