wp_remote_retrieve_body( array|WP_Error $response )
Retrieve only the body from the raw response.
Parameters
- $response
-
(Required) HTTP response.
Return
(string) The body of the response. Empty string if no body or incorrect parameter given.
Source
File: wp-includes/http.php
function wp_remote_retrieve_body( $response ) {
if ( is_wp_error($response) || ! isset($response['body']) )
return '';
return $response['body'];
}
Related
Uses
Uses | Description |
---|---|
wp-includes/load.php: is_wp_error() |
Checks whether the given variable is a WordPress Error. |
Used By
Used By | Description |
---|---|
wp-admin/includes/class-wp-site-health.php: WP_Site_Health::wp_cron_scheduled_check() |
Runs the scheduled event to check and update the latest site health status for the website. |
wp-admin/includes/class-wp-site-health.php: WP_Site_Health::get_test_rest_availability() |
Tests if the REST API is accessible. |
wp-admin/includes/misc.php: wp_check_php_version() |
Checks if the user needs to update PHP. |
wp-includes/https-detection.php: wp_update_https_detection_errors() |
Runs a remote HTTPS request to detect whether HTTPS supported, and stores potential errors. |
wp-admin/includes/update-core.php: cp_get_core_checksums() |
Gets the checksums for the given version of ClassicPress. |
wp-includes/class-wp-http-ixr-client.php: WP_HTTP_IXR_Client::query() | |
wp-includes/deprecated.php: wp_get_http() |
Perform a HTTP HEAD or GET request. |
wp-includes/comment.php: discover_pingback_server_uri() |
Finds a pingback server URI based on the given URL. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::pingback_ping() |
Retrieves a pingback and registers it. |
wp-includes/class-wp-simplepie-file.php: WP_SimplePie_File::__construct() |
Constructor. |
wp-includes/update.php: wp_version_check() |
Checks WordPress version against the newest version. |
wp-includes/update.php: wp_update_plugins() |
Checks for available updates to plugins based on the latest versions hosted on WordPress.org. |
wp-includes/update.php: wp_update_themes() |
Checks for available updates to themes based on the latest versions hosted on WordPress.org. |
wp-includes/class-wp-oembed.php: WP_oEmbed::discover() |
Attempts to discover link tags at the given URL for an oEmbed provider. |
wp-includes/class-wp-oembed.php: WP_oEmbed::_fetch_with_format() |
Fetches result from an oEmbed provider for a specific format and complete provider URL |
wp-includes/rss.php: _fetch_remote_file() |
Retrieve URL headers and content using WP HTTP Request API. |
wp-includes/functions.php: wp_remote_fopen() |
HTTP request for URI to retrieve content. |
wp-admin/includes/network.php: network_step2() |
Prints step 2 for Network installation process. |
wp-admin/includes/translation-install.php: translations_api() |
Retrieve translations from WordPress Translation API. |
wp-admin/includes/plugin-install.php: plugins_api() |
Retrieves plugin installer pages from the ClassicPress.net Plugins API. |
wp-admin/includes/theme.php: themes_api() |
Retrieves theme installer pages from the WordPress.org Themes API. |
wp-admin/includes/file.php: download_url() |
Downloads a URL to a local temporary file using the ClassicPress HTTP API. |
wp-admin/includes/file.php: wp_edit_theme_plugin_file() |
Attempts to edit a file for a theme or plugin. |
wp-admin/includes/import.php: wp_get_popular_importers() |
Returns a list from ClassicPress.net of popular importer plugins. |
wp-admin/includes/dashboard.php: wp_check_browser_version() |
Checks if the user needs a browser update. |
wp-admin/includes/update.php: get_core_checksums() |
Gets and caches the checksums for the given version of WordPress. |
Changelog
Version | Description |
---|---|
2.7.0 | Introduced. |