Add default args list to wp_remote_request|get|post|head docblocks
Props DrewAPicture fixes #23838 git-svn-id: https://develop.svn.wordpress.org/trunk@24250 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
de589f8ebe
commit
8ec3a3a34b
|
@ -49,6 +49,25 @@ function _wp_http_get_object() {
|
|||
* This function is called first to make the request and there are other API
|
||||
* functions to abstract out the above convoluted setup.
|
||||
*
|
||||
* List of default arguments:
|
||||
* 'method' => 'GET'
|
||||
* - Default 'GET' for wp_remote_get()
|
||||
* - Default 'POST' for wp_remote_post()
|
||||
* - Default 'HEAD' for wp_remote_head()
|
||||
* 'timeout' => 5
|
||||
* 'redirection' => 5
|
||||
* 'httpversion' => '1.0'
|
||||
* 'user-agent' => 'WordPress/' . $wp_version . '; ' . get_bloginfo( 'url' )
|
||||
* 'blocking' => true
|
||||
* 'headers' => array()
|
||||
* 'cookies' => array()
|
||||
* 'body' => null
|
||||
* 'compress' => false,
|
||||
* 'decompress' => true,
|
||||
* 'sslverify' => true,
|
||||
* 'stream' => false,
|
||||
* 'filename' => null
|
||||
*
|
||||
* @since 2.7.0
|
||||
*
|
||||
* @param string $url Site URL to retrieve.
|
||||
|
@ -63,7 +82,7 @@ function wp_remote_request($url, $args = array()) {
|
|||
/**
|
||||
* Retrieve the raw response from the HTTP request using the GET method.
|
||||
*
|
||||
* @see wp_remote_request() For more information on the response array format.
|
||||
* @see wp_remote_request() For more information on the response array format and default arguments.
|
||||
*
|
||||
* @since 2.7.0
|
||||
*
|
||||
|
@ -79,7 +98,7 @@ function wp_remote_get($url, $args = array()) {
|
|||
/**
|
||||
* Retrieve the raw response from the HTTP request using the POST method.
|
||||
*
|
||||
* @see wp_remote_request() For more information on the response array format.
|
||||
* @see wp_remote_request() For more information on the response array format and default arguments.
|
||||
*
|
||||
* @since 2.7.0
|
||||
*
|
||||
|
@ -95,7 +114,7 @@ function wp_remote_post($url, $args = array()) {
|
|||
/**
|
||||
* Retrieve the raw response from the HTTP request using the HEAD method.
|
||||
*
|
||||
* @see wp_remote_request() For more information on the response array format.
|
||||
* @see wp_remote_request() For more information on the response array format and default arguments.
|
||||
*
|
||||
* @since 2.7.0
|
||||
*
|
||||
|
|
Loading…
Reference in New Issue