Re: http://bugs.php.net/bugs.php?id=8409
| From: | Andrei Zmievski | Date: | Mon, 08 Jan 2001 18:42:15 +0000 |
| Subject: | Re: http://bugs.php.net/bugs.php?id=8409 | ||
| References: | 1 2 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-43421@lists.php.net to get a copy of this message | ||
On Mon, 08 Jan 2001, Stig Venaas wrote:
> This sounds like a good idea, should be backwards compatible. Except
> that I think the result should be
>
> creates $prefix0, $prefix1, and $prefix2 in your case. After all the
> indices are 0, 1 and 2, and adding _ doesn't seem natural. You can
> call your prefix prefix_ then.
In retrospect, I shouldn't have had extract() append _ automatically. If
you change it now, you will break all the scripts that use prefix
option, though.
> To return the number of variables sounds good to me, but won't it
> always be the same as the number of elements in the array?
No, it won't. If you don't use the prefix option, some of the key values
may not constitute valid variable names and won't be extracted.
-Andrei
* The great thing about standards is that there are so many to choose from. *