Reply to Re: get object value

Your name:

Reply:


Posted by IchBin on 11/02/63 11:55

ImOk wrote:
> Did you even run this code? Your code is full of syntax and runtime
> errors. Here is the fixed up version.

[snip code]

> function makelist( ){
> $vector=array();
> $aShop = new Shop();
> for( $i=0;$i<10;$i++){
> $aShop->setID($i);
> $aShop->setName("shopname".$i);
> $vector[]=$aShop;
> }
> return $vector;
> }
>

[snip code]

I think you want to change you makelist() function to look like this:

function makelist( )
{
$vector = array();

for( $i=0;$i<10;$i++)
{
$aShop = new Shop();
$aShop->setID($i);
$aShop->setName("shopname".$i);
$vector[]=$aShop;
}
return $vector;
}

Thanks in Advance...
IchBin, Pocono Lake, Pa, USA http://weconsultants.phpnet.us
__________________________________________________________________________

'If there is one, Knowledge is the "Fountain of Youth"'
-William E. Taylor, Regular Guy (1952-)

--

Thanks in Advance...
IchBin, Pocono Lake, Pa, USA http://weconsultants.phpnet.us
__________________________________________________________________________

'If there is one, Knowledge is the "Fountain of Youth"'
-William E. Taylor, Regular Guy (1952-)

[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

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