WP_Image_Editor::multi_resize()
Resize multiple images from a single source.
Method of the class: WP_Image_Editor{}
No Hooks.
Return
Array
. An array of resized images metadata by size.
Usage
$WP_Image_Editor = new WP_Image_Editor(); $WP_Image_Editor->multi_resize( $sizes );
- $sizes(array) (required)
An array of image size arrays.
Default: sizes are 'small', 'medium', 'large'
-
...$0(array)
-
width(int)
Image width. -
height(int)
Image height. - crop(true|false|array)
Optional. Whether to crop the image.
Default: false
-
-
Changelog
Since 3.5.0 | Introduced. |
WP_Image_Editor::multi_resize() WP Image Editor::multi resize code WP 6.6.2
abstract public function multi_resize( $sizes );