I defined custom thumbnail sizes in my functions.php file using this function:
add_theme_support( 'post-thumbnails' );
if ( function_exists( 'add_image_size' ) ) {
add_image_size( 'address', 960, 250, true );
}
Which works fine as long as I don’t use the ‘Edit Image’ function (crop tool) in the WordPress back-end, after uploading my image. When I do so, the height that I defined (250px) is not considered anymore.
Has anyone else encountered this problem and knows how to solve it?
It is a known problem. I’ve read somewhere that it will be solved in one of the upcoming releases. Until then you can use the following code in your
functions.php
. Just adjust the image sizes.The ‘Edit Image’ function is considering only the original file (‘full’) image for cropping , resize, rotate and other minor “editing” . you have an option there to specify if you want it for all sizes, only thumbnails, or all sizes except thumbnails..