Re: printing values from a 2 dimension array
| From: | Jason Wong | Date: | Wed, 15 Oct 2003 16:31:10 +0000 |
| Subject: | Re: printing values from a 2 dimension array | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-166225@lists.php.net to get a copy of this message | ||
On Wednesday 15 October 2003 22:05, bob pilly wrote:
> Yes it is what i expect to be stored in the array.
[snip]
> That is one array stored in $rslt[0] and another in $rslt[1] (perhaps i
> am not understanding arrays correctly?)
>
> The thing that confuses me is if i assign the contents of an array member
> to a variable, and then print it, i get the result i am after,for example
>
> $avar = $rslt[0][1];print $avar;
> will return '4' as i would expect from the output of print_r.
Well it *should* work. If you go back to the code that you posted at the
beginning of this thread, correct the errors and run it, you'll see that it
works fine.
--
Jason Wong -> Gremlins Associates -> www.gremlins.biz
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *
------------------------------------------
Search the list archives before you post
http://marc.theaimsgroup.com/?l=php-general
------------------------------------------
/*
We will have solar energy as soon as the utility companies solve one technical
problem -- how to run a sunbeam through a meter.
*/