You are here: Re: Multidimensional associated array « PHP Programming Language « IT news, forums, messages
Re: Multidimensional associated array

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]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация