|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2016-01-15 08:11 UTC] simonsimcity at gmail dot com
[2016-01-15 08:11 UTC] simonsimcity at gmail dot com
[2018-01-11 19:01 UTC] gonzad26 at gmail dot com
[2018-01-11 19:05 UTC] spam2 at rhsoft dot net
[2018-01-11 20:25 UTC] gonzad26 at gmail dot com
[2019-08-05 17:31 UTC] cmb@php.net
-Status: Open
+Status: Verified
-Type: Bug
+Type: Documentation Problem
[2019-08-05 17:31 UTC] cmb@php.net
[2021-09-24 15:56 UTC] git@php.net
[2021-09-24 15:56 UTC] git@php.net
-Status: Verified
+Status: Closed
[2021-09-24 16:10 UTC] git@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Thu Oct 23 03:00:01 2025 UTC |
Description: ------------ Basically if you're parsing a random HTML sometimes users will put new lines in the href attribute of a tags, browsers ignore the new line, but PHP converts it to an underscore. Test script: --------------- $ php -r 'var_export(parse_url("http://example.com/foo\nbar"));' Expected result: ---------------- The expected output is: $ php -r 'var_export(parse_url("http://example.com/foo\nbar"));' array ( 'scheme' => 'http', 'host' => 'example.com', 'path' => '/foobar', ) Actual result: -------------- The actual output is: $ php -r 'var_export(parse_url("http://example.com/foo\nbar"));' array ( 'scheme' => 'http', 'host' => 'example.com', 'path' => '/foo_bar', )