apply_filters( 'image_resize_dimensions', null|mixed $null, int $orig_w, int $orig_h, int $dest_w, int $dest_h, bool|array $crop )

Filters whether to preempt calculating the image resize dimensions.

Description Description

Passing a non-null value to the filter will effectively short-circuit image_resize_dimensions(), returning that value instead.

Parameters Parameters


(null|mixed) Whether to preempt output of the resize dimensions.


(int) Original width in pixels.


(int) Original height in pixels.


(int) New width in pixels.


(int) New height in pixels.


(bool|array) Whether to crop image to specified width and height or resize. An array can specify positioning of the crop area. Default false.

In WordPress theme and development, Hooks are functions that can be applied to an Action or a Filter in WordPress. Actions and Filters in WordPress are functions that can be altered by theme and plugin developers to change the default WordPress functionality.

Functions used to alter Actions/Filters in WordPress can be hooked into WordPress. In any case, note that actions and filters are not some thing very similar. Actions are functions performed when a specific occasion happens in WordPress. Filters enable you to change certain functions. Arguments used to hook the two filters and actions appear to be identical. Be that as it may, they are different in functionality and how they carry on.