You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Colon in url path is not parsed by parse_url #12703
parse_url() return false on absolute path containing : and no query string.
The following code:
<?phpvar_dump(parse_url('/page:1?foo=bar')); // Working example of parsing.var_dump(parse_url('/page:1'));
var_dump(parse_url('/page:1', \PHP_URL_SCHEME));
We should still fix this case IMHO. The engine currently fails to parse valid URLs.
I implemented a workaround in symfony/symfony#58218 but this is not pretty :)
Activity
nicolas-grekas commentedon Sep 10, 2024
We should still fix this case IMHO. The engine currently fails to parse valid URLs.
I implemented a workaround in symfony/symfony#58218 but this is not pretty :)
bug #58218 Work around `parse_url()` bug (nicolas-grekas)
Fix phpGH-12703 and optimize parse_url control-char replacement
Fix phpGH-12703 and optimize parse_url control-char replacement
TimWolla commentedon Apr 11, 2026
Please migrate to the new ext/uri classes (
Uri\*namespace) instead. See also php/doc-en#5477.