Docs: Clarify `download_url()` return value, improve DocBlock formatting.
See #42505. Built from https://develop.svn.wordpress.org/trunk@42775 git-svn-id: http://core.svn.wordpress.org/trunk@42605 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
7b7ca428f3
commit
3c8ae81018
|
@ -958,14 +958,15 @@ function wp_handle_sideload( &$file, $overrides = false, $time = null ) {
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Downloads a URL to a local temporary file using the WordPress HTTP Class.
|
* Downloads a URL to a local temporary file using the WordPress HTTP API.
|
||||||
* Please note, That the calling function must unlink() the file.
|
*
|
||||||
|
* Please note that the calling function must unlink() the file.
|
||||||
*
|
*
|
||||||
* @since 2.5.0
|
* @since 2.5.0
|
||||||
*
|
*
|
||||||
* @param string $url the URL of the file to download
|
* @param string $url The URL of the file to download.
|
||||||
* @param int $timeout The timeout for the request to download the file default 300 seconds
|
* @param int $timeout The timeout for the request to download the file. Default 300 seconds.
|
||||||
* @return mixed WP_Error on failure, string Filename on success.
|
* @return string|WP_Error Filename on success, WP_Error on failure.
|
||||||
*/
|
*/
|
||||||
function download_url( $url, $timeout = 300 ) {
|
function download_url( $url, $timeout = 300 ) {
|
||||||
//WARNING: The file is not automatically deleted, The script must unlink() the file.
|
//WARNING: The file is not automatically deleted, The script must unlink() the file.
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
*
|
*
|
||||||
* @global string $wp_version
|
* @global string $wp_version
|
||||||
*/
|
*/
|
||||||
$wp_version = '5.0-alpha-42774';
|
$wp_version = '5.0-alpha-42775';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||||
|
|
Loading…
Reference in New Issue