intermediate_image_sizes WordPress Filter Hook
The intermediate_image_sizes hook is used to filter the image sizes that are generated when an image is uploaded. This can be useful for plugins that need to generate their own image sizes or for themes that need to override the default image sizes.
apply_filters( 'intermediate_image_sizes', string[] $default_sizes ) #
Filters the list of intermediate image sizes.
Parameters
- $default_sizes
(string[])An array of intermediate image size names. Defaults are 'thumbnail', 'medium', 'medium_large', 'large'.
More Information
The $default_sizes
parameter also contains all image sizes registered with add_image_size()
Source
File: wp-includes/media.php
Changelog
Version | Description |
---|---|
2.5.0 | Introduced. |