mirror of
git://develop.git.wordpress.org/
synced 2025-04-21 04:31:55 +02:00
Docs: Improve and update the description of multi_resize()
to explain changes and expected use.
See #40439. git-svn-id: https://develop.svn.wordpress.org/trunk@45892 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
252e14ac27
commit
152083be8f
@ -197,16 +197,24 @@ class WP_Image_Editor_GD extends WP_Image_Editor {
|
||||
}
|
||||
|
||||
/**
|
||||
* Resize multiple images from a single source.
|
||||
* Create multiple smaller images from a single source.
|
||||
*
|
||||
* Attempts to create all sub-sizes and returns the meta data at the end. This
|
||||
* may result in the server running out of resources. When it fails there may be few
|
||||
* "orphaned" images left over as the meta data is never returned and saved.
|
||||
*
|
||||
* As of 5.3.0 the preferred way to do this is with `make_subsize()`. It creates
|
||||
* the new images one at a time and allows for the meta data to be saved after
|
||||
* each new image is created.
|
||||
*
|
||||
* @since 3.5.0
|
||||
*
|
||||
* @param array $sizes {
|
||||
* An array of image size arrays. Default sizes are 'small', 'medium', 'medium_large', 'large'.
|
||||
* An array of image size data arrays.
|
||||
*
|
||||
* Either a height or width must be provided.
|
||||
* If one of the two is set to null, the resize will
|
||||
* maintain aspect ratio according to the provided dimension.
|
||||
* maintain aspect ratio according to the source image.
|
||||
*
|
||||
* @type array $size {
|
||||
* Array of height, width values, and whether to crop.
|
||||
|
@ -410,12 +410,20 @@ class WP_Image_Editor_Imagick extends WP_Image_Editor {
|
||||
}
|
||||
|
||||
/**
|
||||
* Resize multiple images from a single source.
|
||||
* Create multiple smaller images from a single source.
|
||||
*
|
||||
* Attempts to create all sub-sizes and returns the meta data at the end. This
|
||||
* may result in the server running out of resources. When it fails there may be few
|
||||
* "orphaned" images left over as the meta data is never returned and saved.
|
||||
*
|
||||
* As of 5.3.0 the preferred way to do this is with `make_subsize()`. It creates
|
||||
* the new images one at a time and allows for the meta data to be saved after
|
||||
* each new image is created.
|
||||
*
|
||||
* @since 3.5.0
|
||||
*
|
||||
* @param array $sizes {
|
||||
* An array of image size arrays. Default sizes are 'thumbnail', 'medium', 'medium_large', 'large'.
|
||||
* An array of image size data arrays.
|
||||
*
|
||||
* Either a height or width must be provided.
|
||||
* If one of the two is set to null, the resize will
|
||||
|
Loading…
x
Reference in New Issue
Block a user