note 7527 deleted from Returning values by torben

From: Date: Sat, 19 Aug 2000 22:46:18 +0000
Subject: note 7527 deleted from Returning values by torben
Groups: php.notes 
Request: Send a blank email to php-notes+get-2683@lists.php.net to get a copy of this message
That '&' preceding the argument in the function call tells php to pass the variable by reference rather than by value. That means that while the function is performing it's operation the value of the original variable can be affected. So you're not really passing in return values. Rather you are permitting your arguments to be mutable. Is there a limit on the size of string that can be returned by a function? I recently built a function to build html tables of a specified row x column size that takes row and col as arguments. It places the entire string into a variable and returns it. As far as I can tell I'm not getting a return value at all. I know that the string is correct because a print statement in the function itself shows the desired output.

« previous php.notes (#2683) next »