Re: register globals -> PHP6 still replaces . in variables from outside
| From: | Kalle Sommer Nielsen | Date: | Tue, 11 Nov 2008 22:13:09 +0000 |
| Subject: | Re: register globals -> PHP6 still replaces . in variables from outside | ||
| References: | 1 2 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-41859@lists.php.net to get a copy of this message | ||
Hi Mark
2008/11/11 Mark van der Velden <mark@dynom.nl>:
> Sorry for bringing an old thread back to life, but imo this needs some
> more attention.
>
>
> Sebastian wrote:
>> hi,
>>
>> PHP6 still replaces "." with an underscore in variables from outside. this
>> is an old behavior forced by register globals so i would say its a bug since
>> "." is valid in array keys.
>>
>> for sample:
>>
>> call a script like http://www.example.com/?my.var=1
>>
>> now $_GET will look like this:
>>
>> Array ( [my_var] => 1)
>>
>> Thanks
>>
>
> It's a valid HTML input name attribute character [1] and imo the
> replacement feature (where ' ' and '.' characters are replaced to
> '_')
> should be removed in PHP 6, when the register_globals feature is removed.
>
> There will be PHP applications that need changing, but I estimate that
> it will be fixed easily. And since PHP 6 is breaking a lot anyway, what
> other version would be more suitable to change this.
I don't see it would work with something like
import_request_variables() unless thats removed or extract(), which is
some of the reasons for this replacement feature afair.
>
>
> [1] - http://www.w3schools.com/TAGS/att_input_name.asp
>
>
> - Mark
>
> --
> PHP Internals - PHP Runtime Development Mailing List
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
Kalle Sommer Nielsen