#29886 closed defect (bug) (fixed)
WP_HTTP::make_absolute_url() treats schemeless URLs as relative
Reported by: | dd32 | Owned by: | dd32 |
---|---|---|---|
Milestone: | 4.1 | Priority: | normal |
Severity: | normal | Version: | 4.1 |
Component: | HTTP API | Keywords: | |
Focuses: | Cc: |
Description
Currently if you pass WP_HTTP::make_absolute_url()
a scheme-less url, it's converted to a absolute url based on the current domain, ignoring the host of the schemeless url.
Although Schemeless URL's are invalid in HTTP Headers, since this is a helper function used elsewhere, and because many systems don't follow the specifications strictly, we should handle schemeless url's correctly.
The correct option for this function appears to be to convert it to a protocol relative url, safe for use in a HTTP request.
Change History (5)
#3
@
10 years ago
This test is failing in php 5.2
https://travis-ci.org/aaronjorbin/develop.wordpress/jobs/37362400
Note: See
TracTickets for help on using
tickets.
In 29851: