Hi all

I am having problems printing members of an array that has two dimensions and am wondering if someone can help me with the syntax required to do this.

If i have the follwing code:
<?php
$test=array('test1'=>'a','test2'=>'b');
print "$test[test1]";
?>

I get 'a' echoed to the screen as expected. But if i make the array 2 dimensional like this:

<?php
$test[0]=array('test1'=>'a','test2'=>'b');
print "$test[0][test1]";
?>

I would expect to get 'a' echoed to the screen again but instead i get this:
Array[test1].

Has anyone seen this before and can help or point me to some goods docs on it?

Thanks in advance for any help

Cheers

Bob

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Reply via email to