mirror of
https://github.com/php/php-src.git
synced 2026-04-27 18:23:26 +02:00
5a9f5a6514
Relates to #14461 and https://wiki.php.net/rfc/url_parsing_api Co-authored-by: Niels Dossche <7771979+nielsdos@users.noreply.github.com> Co-authored-by: Tim Düsterhus <tim@tideways-gmbh.com>
16 lines
399 B
PHP
16 lines
399 B
PHP
--TEST--
|
|
Test recomposition of URIs
|
|
--EXTENSIONS--
|
|
uri
|
|
--FILE--
|
|
<?php
|
|
|
|
var_dump(Uri\Rfc3986\Uri::parse("http://example.com?foo=Hell%C3%B3+W%C3%B6rld")->toRawString());
|
|
|
|
var_dump(Uri\WhatWg\Url::parse("http://example.com?foo=Hell%C3%B3+W%C3%B6rld")->toAsciiString());
|
|
|
|
?>
|
|
--EXPECT--
|
|
string(44) "http://example.com?foo=Hell%C3%B3+W%C3%B6rld"
|
|
string(45) "http://example.com/?foo=Hell%C3%B3+W%C3%B6rld"
|