A WordPress-centric search engine for devs and theme authors



image_downsize ›

Since2.5.0
Deprecatedn/a
apply_filters( 'image_downsize', false, $id, $size )
Parameters: (3)
  • (bool|array) $downsize Whether to short-circuit the image downsize.
    Required: Yes
  • (int) $id Attachment ID for image.
    Required: Yes
  • (string|int[]) $size Requested image size. Can be any registered image size name, or an array of width and height values in pixels (in that order).
    Required: Yes
Defined at:
Codex:

Filters whether to preempt the output of image_downsize().

Returning a truthy value from the filter will effectively short-circuit down-sizing the image, returning that value instead.





Source

$out = apply_filters( 'image_downsize', false, $id, $size );