|
Posted by Norman Peelman on 01/14/08 00:20
Peter Pei wrote:
> <?php
> $a = array(array("a"=>1, "b"=>2));
> print "{$a[0][b]}";
> ?>
> this gives you notice,
Yes, that's what I said. When using multi-dimensional arrays within
double-quoted strings you must use the { }'s... and when you use the {
}'s you must use single quotes around the key names. PHP does not search
for CONSTANTS within double-quoted strings, there is a very specific
reason for it.
--
Norman
Registered Linux user #461062
Navigation:
[Reply to this message]
|