[Phpmyadmin-devel] regexp question
Marc Delisle
Marc.Delisle at cegepsherbrooke.qc.ca
Sat Mar 18 03:22:00 CET 2006
Sebastian Mendel a écrit :
> Marc Delisle schrieb:
>
>> Hi,
>> in this line:
>> $is_gotofile = preg_replace('@^([^?]+).*$@', '\\1', $goto);
>>
>> does the character class [^?] mean "a character different than the
>> question mark" ?
>
> yes
>
>> What's the goal of this line?
>
> all after first '?' is removed
>
>
> script.php?var=1&var2=44
>
> becomes
>
> script.php
>
>
Ok, in the bug I'm working on, instead of a "?" it's a "%3F" so the test does
not work. I'll check if it would be safe to always urldecode() at this point.
Marc
More information about the Developers
mailing list