Skip to content

Recommend ext/uri over parse_url() #5450

@iluuu1994

Description

@iluuu1994

Affected page

https://www.php.net/manual/en/function.parse-url.php

Current issue

ext/uri was introduced to fix long-standing issues with parse_url(). parse_url() does not strictly follow any particular spec, does not correctly handle parsing of relative URLs, and accepts invalid URLs that can circumvent sanitization checks.

See https://wiki.php.net/rfc/url_parsing_api for more details.

Suggested improvement

There should be a note that encourages the use of ext/uri over parse_url().

Additional context (optional)

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions