[wp-trac] [WordPress Trac] #40142: WP Remote Remaining Methods
WordPress Trac
noreply at wordpress.org
Wed Apr 19 00:28:28 UTC 2023
#40142: WP Remote Remaining Methods
------------------------------------------+------------------------------
Reporter: bhubbard | Owner: (none)
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: HTTP API | Version: 2.7
Severity: normal | Resolution:
Keywords: needs-patch needs-unit-tests | Focuses:
------------------------------------------+------------------------------
Comment (by pingram3541):
I know this is an old one and if there is a better approach than making
our own function like:
{{{
function wp_safe_remote_delete( $url, $args = array() ) {
$args['reject_unsafe_urls'] = true;
$http = _wp_http_get_object();
return $http->delete( $url, $args );
}
}}}
I'd love to know. Otherwise, I also like the idea of passing the method
via $args to a universal function like:
{{{
wp_safe_remote_http_request( $url, $args );
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/40142#comment:15>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list