Re: Returning arrays from functions

From: Date: Tue, 05 Dec 2000 18:33:11 +0000
Subject: Re: Returning arrays from functions
Groups: php.dev 
Request: Send a blank email to php-dev+get-40157@lists.php.net to get a copy of this message
Never mind. A buggy piece of code and a confused mind were the cause. My function wasn't returning an array, and so i remembered reading in the docs you couldn't return arrays. Actually what you can't return is multiple values which is solved by using the array() function. <borrows a towel to wipe the egg off his face> ----- Brendan W. McAdams | email: bmcadams@scalabletech.com Web Developer, Scalable Technologies | web: www.scalabletech.com "Always listen to the experts; they'll tell you what can't be done, and why. Then do it." - Robert A. Heinlein ----- Original Message ----- From: "Andrei Zmievski" <andrei@ispi.net> To: "Brendan W. McAdams" <bmcadams@scalabletech.com> Cc: <php-dev@lists.php.net> Sent: Tuesday, December 05, 2000 1:15 PM Subject: Re: [PHP-DEV] Returning arrays from functions On Tue, 05 Dec 2000, Brendan W. McAdams wrote: > I notice it still isn't possible to directly return an array from a > function; I find this rather annoying, as it makes heavy programming > unwieldy at times. > > I'm wondering if this is a 'bug' or a 'feature' (is it because nobody > has > fixed function returns to allow arrays, or is it done on purpose?). Could you please clarify what you mean by 'directly return an array from a function'? -Andrei * I wish life had an UNDO function. *

« previous php.dev (#40157) next »