xref: /PHP-7.3/ext/standard/tests/url/bug68917.phpt (revision d7fb52ea)
1--TEST--
2Bug #68917 (parse_url fails on some partial urls)
3--FILE--
4<?php
5print_r(parse_url('//example.org:81/hi?a=b#c=d'));
6print_r(parse_url('//example.org/hi?a=b#c=d'));
7?>
8--EXPECT--
9Array
10(
11    [host] => example.org
12    [port] => 81
13    [path] => /hi
14    [query] => a=b
15    [fragment] => c=d
16)
17Array
18(
19    [host] => example.org
20    [path] => /hi
21    [query] => a=b
22    [fragment] => c=d
23)
24