Uses
Uses | Description |
---|---|
wp-includes/load.php: is_wp_error() | Check whether variable is a WordPress Error. |
Retrieve only the response message from the raw response.
Will return an empty array if incorrect parameter value is given.
(array|WP_Error) (Required) HTTP response.
(string) The response message. Empty string on incorrect parameter given.
File: wp-includes/http.php
function wp_remote_retrieve_response_message( $response ) { if ( is_wp_error( $response ) || ! isset( $response['response'] ) || ! is_array( $response['response'] ) ) { return ''; } return $response['response']['message']; }
Version | Description |
---|---|
2.7.0 | Introduced. |
© 2003–2019 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/functions/wp_remote_retrieve_response_message