You are here: Re: Make a function that returns more than one value? « All PHP « IT news, forums, messages
Re: Make a function that returns more than one value?

Posted by J.O. Aho on 09/25/06 18:07

Oli Filth wrote:
> The87Boy said the following on 25/09/2006 16:44:
>> Is there any ways to make a function like system(), which returns more
>> than one value (true or false) and (the array)
>
> A function can have only one return value. However, it can alter
> variables passed in by reference, which is what happens with system().
>
> See http://uk.php.net/manual/en/language.references.php.

Another option is to use an array to return the values you want to be
returned, of course this will not be in the same manner as system() does, but
can sometimes be a smother way to return multiple values.


//Aho

 

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

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