Reply to Re: Cannot get this one correct and working, though simple!

Your name:

Reply:


Posted by comp.lang.php on 01/03/06 19:50

Oli Filth wrote:
> comp.lang.php said the following on 30/12/2005 16:16:
> > Jofio wrote:
> >
> >>
> >>But my problem is that part of the code ...<img src='thumb$i.jpg'> ...
> >>
> >
> > The problem lies in the way you embedded $i. PHP thinks you have a
> > variable literally called "$i.jpg" since a period is a valid implied
> > variable name character.
> >
>
> Umm, no... Who told you that?

The PHP manual. Assuming that is still your authority on PHP.

"Variable names follow the same rules as other labels in PHP. A valid
variable name starts with a letter or underscore, followed by any
number of letters, numbers, or underscores. As a regular expression, it
would be expressed thus: '[a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]*'"

>From http://us3.php.net/language.variables

Sorry to be off-topic.

Phil

>
> The problem is the use of single quotes rather than double quotes.
>
> --
> Oli

[Back to original 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

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