Reply to Re: sytax error, but where?

Your name:

Reply:


Posted by carlton on 10/30/05 12:32

Janwillem Borleffs wrote:
> carlton wrote:
>
>>I added the var to line 44, and now get the error
>>Parse error: parse error, unexpected '[', expecting ',' or ';' in
>>/var/www/html/lc.php on line 44
>>
>>line 44 is var $PictureList[] = new C_PictureList();
>>
>
>
> You should assign $PictureList in the constructor or with a setter:
>
> class C_Category {
> var $PictureList = array();
>
> function C_Category() {
> $this->PictureList[] = new C_PictureList();
> }
> }
>
>
> JW
>
>
>
PictureList[] is supposed to be an array of C_PictureList objects, not a
member of the C_PictureList class.

[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

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