WordPress.org

Make WordPress Core

Changeset 34362


Ignore:
Timestamp:
09/21/2015 10:21:48 AM (4 years ago)
Author:
DrewAPicture
Message:

Docs: Add a more complete return description for the array of data (or false) returned by image_downsize().

If not short-circuited via the image_downsize boolean filter, image_downsize() returns an array of data including the image URL, width, height, and whether the image size is intermediate, in that order. Otherwise, it returns false.

Fixes #30636.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/media.php

    r34261 r34362  
    149149 * @param array|string $size Optional. Image size to scale to. Accepts a registered image size
    150150 *                           or flat array of height and width values. Default 'medium'.
    151  * @return false|array False on failure, array on success.
     151 * @return false|array Array containing the image URL, width, height, and boolean for whether
     152 *                     the image is an intermediate size. False on failure.
    152153 */
    153154function image_downsize( $id, $size = 'medium' ) {
Note: See TracChangeset for help on using the changeset viewer.