Definition:
function wp_shrink_dimensions( $width, $height, $wmax = 128, $hmax = 96 ) {}
Calculates the new dimensions for a downsampled image.
Parameters
- int $width: Current width of the image
- int $height: Current height of the image
- int $wmax: Maximum wanted width
- int $hmax: Maximum wanted height
Return values
returns:Array(height,width) of shrunk dimensions.
Source code
function wp_shrink_dimensions( $width, $height, $wmax = 128, $hmax = 96 ) { _deprecated_function( __FUNCTION__, '3.0', 'wp_constrain_dimensions()' ); return wp_constrain_dimensions( $width, $height, $wmax, $hmax ); }
4127
No comments yet... Be the first to leave a reply!