Image dimensions same as image size

No, it won’t create a new image that is exactly the same size.. nor should it. All the thumbnail, medium, and large images are resized images, by definition. Since the original image is already 600×600, there’s no point in creating another file at the same size, but with a lower quality (remember that JPEG compression is lossy).

However, if you specify in the template call that you want to use the large image size with something like <?php echo get_the_post_thumbnail( $post->ID, 'large' ); ?>, and there is no “large” size available for that image, then it will actually use the full sized image, not the medium sized one. It always chooses “up”, basically.

See, whenever you specify an image size like large or medium or even array(400,400), then what WordPress does is to pick the next larger size image that it can find and then it uses that, along with width/height rules in the IMG tag to make the browser resize it down. It does this because images look like crap when sized up, but reasonably okay when sized down.

So yes, even without the large image size being created, specifying the “large” size as a size in the template is okay and will work correctly. I’ve just tested this on a test site, using this exact code and sizing, and it works properly. Specifying the large size made it actually use the URL of the full size, not the medium one.

Leave a Comment