> On Jun 29, 2024, at 03:20, nyamsprod the funky webmaster <[email protected]> wrote:
>
> Therefore, I would rather suggest we ALSO include support for RFC3986 and RFC3987 specification
> properly and give both specs a go (at the same time!) and a clear way to instantiate your
> Url
with one or the other spec.
> In clear, my ideal situation would be to add to the parser at least 2 named constructors
> UrlParser::fromRFC3986
and UrlParser::fromWHATWG
> or something similar (name can be changed or improved).
>
> While this is an old article by Daniel Stenberg
> (https://daniel.haxx.se/blog/2017/01/30/one-url-standard-please/), it conveys with more in depth
> analysis my issues with the WHATWG spec and its usage in PHP if it were to be use as the ONLY
> available parser in PHP core for URL.
I agree that I would love to see a more general IRI parser, with maybe a URI parser being a subtype
of an IRI parser.
Cheers,
Ben