#35691 closed enhancement (wontfix)
New function: `wp_get_protocol`
Reported by: | sebastian.pisula | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | |
Component: | General | Keywords: | |
Focuses: | Cc: |
Description
In many locations I can see this condition: ( is_ssl() ? 'https://' : 'http://' )
. Code duplication is bad.
Attachments (1)
Change History (5)
Note: See
TracTickets for help on using
tickets.
We also have
set_url_scheme( 'http://example.com/' )
at our disposal too, which is probably preferential to this proposal.