Bug #71646 [Opn]: parse_url fails to parse relative url with port-like string in url

From: Date: Tue, 23 Feb 2016 12:04:47 +0000
Subject: Bug #71646 [Opn]: parse_url fails to parse relative url with port-like string in url
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-199416@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=71646&edit=1 ID: 71646 Updated by: cmb@php.net Reported by: jona at mode dot com Summary: parse_url fails to parse relative url with port-like string in url Status: Open Type: Bug Package: URL related Operating System: linux PHP Version: 5.6.18 Block user comment: N Private report: N New Comment: This appears to be a duplicate of bug #70942. Previous Comments: ------------------------------------------------------------------------ [2016-02-22 18:28:30] jona at mode dot com Description: ------------ When a relative URL without a scheme and port, but with a port-like string (e.g. /example.com/foo:1234) is passed to parse_url(), it fails to parse the URL (returning false). Test script: --------------- var_dump(parse_url("/foo/bar:1")); Expected result: ---------------- array(1) { ["path"]=> string(10) "/foo/bar:1" } Actual result: -------------- false ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=71646&edit=1

« previous php.bugs (#199416) next »