You are here: Re: explode « All PHP « IT news, forums, messages
Re: explode

Posted by Oli Filth on 09/14/05 20:30

Geoff Berrow said the following on 14/09/2005 18:07:
> I noticed that Message-ID: <5pYVe.5204$hQ4.333@newsfe4-win.ntli.net>
> from Oli Filth contained the following:
>
>
>>Ummm:
>>
>> $word = "single";
>> echo $word[0] . " " . $word[1] . " " . $word[2];
>>
>>Although, this isn't a proper array.
>
>
> Ummmm...ITYM
>
> $word = "single";
> echo $word{0} . " " . $word{1} . " " . $word{2};
>

I believe that curly braces are the recommended practice as of PHP 4,
but square brackets work too.

The point was to show that the OP's original code was essentially
correct as it was.


--
Oli

 

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

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