WP_Image_Editor::multi_resize

SummerySummery

Resize multiple images from a single source.

Syntax

WP_Image_Editor::multi_resize( array $sizes )

ParametersParameters

$sizes

(array) (Required) An array of image size arrays. Default sizes are 'small', 'medium', 'large'.

  • 'size'
    (array)
    • 'width'
      (int) Image width.
    • 'height'
      (int) Image height.
    • 'crop'
      (bool) Optional. Whether to crop the image. Default false.

ReturnReturn

(array) An array of resized images metadata by size.

SourceSource

File: wp-includes/class-wp-image-editor.php


			

ChangelogChangelog

Changelog
Version Description
3.5.0 Introduced.
Scroll to Top