Re: printing values from a 2 dimension array
| From: | Jason Wong | Date: | Wed, 15 Oct 2003 10:34:20 +0000 |
| Subject: | Re: printing values from a 2 dimension array | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-166183@lists.php.net to get a copy of this message | ||
On Wednesday 15 October 2003 17:44, bob pilly wrote:
> Im having problems printing values from a 2 dimensional array:
> If i have:
> temp[0]=array(0,10,11);
> temp[1]=array(a,b,c);
> print $temp[0][1];
>
> i expected the output to be '10' instead i get 'Array[1]', however if i
> use:
>
> $var=$temp[0][1];print $var; i get '10' as the output. This is fine but it
> defeats the purpose of what i am trying to do, can anyone tell me why this
> is happening? Im new to arrays and its fairly confusing. Thanks for any
> help in advance!
Try posting your *real* code. The above should not even run.
--
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
------------------------------------------
/*
Chairman of the Bored.
*/