Title: Wrong Image Size
Last modified: August 31, 2016

---

# Wrong Image Size

 *  Resolved [Dave Chimny](https://wordpress.org/support/users/netzblogr/)
 * (@netzblogr)
 * [10 years, 2 months ago](https://wordpress.org/support/topic/wrong-image-size/)
 * After updating to version 1.5, the full size of the teaser image is shown instead
   of the size that was defined in the theme:
 * I defined `the_post_thumbnail(array(620, 150));` – in version 1.4 it used the
   version of the image with the next size available (in my case 930×225) and scaled
   it down with `<img width="620" height="150" ...>`) correctly.
 * [https://wordpress.org/plugins/default-featured-image/](https://wordpress.org/plugins/default-featured-image/)

Viewing 4 replies - 1 through 4 (of 4 total)

 *  Plugin Author [Jan-Willem](https://wordpress.org/support/users/janwoostendorp/)
 * (@janwoostendorp)
 * [10 years, 2 months ago](https://wordpress.org/support/topic/wrong-image-size/#post-7282827)
 * Hi Falk,
 * That’s annoying. All I did in 1.5 was add a class if you used a custom size. 
   Like you do.
    Can you send me a link of the page where it is happening?
 * I’d like to debug this better. What theme are you using? Wehere did you define
   the `the_post_thumbnail(array(620, 150));`?
 * If it is a custom theme is it possible I can get it for debugging?
 *  Thread Starter [Dave Chimny](https://wordpress.org/support/users/netzblogr/)
 * (@netzblogr)
 * [10 years, 2 months ago](https://wordpress.org/support/topic/wrong-image-size/#post-7282832)
 * Hi Jan,
 * it’s a self-made theme. Maybe not the best webwork in the world, but it works
   for me. 🙂
 * For testing, I switched the lazy loading off, to eliminate this as a cause. Then
   I compared version 1.4 with 1.5 and found out that the lines 204 to 206 cause
   the problem:
 *     ```
       if ( is_array($size)) {
       	$size = 'size-' . implode( 'x', $size);
       }
       ```
   
 * After deleting this part, all was shown as before. I don’t know why this overwrites
   WordPress’ settings – it doesn’t look that harmful.
 * Next I changed the code of my _single.php_ to `the_post_thumbnail(thumbnail);`,
   but I had to resize it with CSS to fit into the non-responsive div. That’s what
   I went around with the size array.
 * You can see the default image in action [in this article](https://www.netzblogr.com/islamophobie-anschaulich-erklaert).
 * For me this is resolved, but I’d really like to know why this little code snippet
   makes such a mess. O.o
 *  Plugin Author [Jan-Willem](https://wordpress.org/support/users/janwoostendorp/)
 * (@janwoostendorp)
 * [10 years, 2 months ago](https://wordpress.org/support/topic/wrong-image-size/#post-7282853)
 * I have found and fixed the issue.
    That code you showed was new. It should add
   a valid class to the html. I forgot the `$size` was also used after that.
 * So 1.6 should fix that.
    Could you try?
 *  Thread Starter [Dave Chimny](https://wordpress.org/support/users/netzblogr/)
 * (@netzblogr)
 * [10 years, 2 months ago](https://wordpress.org/support/topic/wrong-image-size/#post-7282854)
 * Yes, it’s fixed. 🙂

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Wrong Image Size’ is closed to new replies.

 * ![](https://ps.w.org/default-featured-image/assets/icon-256x256.jpg?rev=1058491)
 * [Default Featured Image](https://wordpress.org/plugins/default-featured-image/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/default-featured-image/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/default-featured-image/)
 * [Active Topics](https://wordpress.org/support/plugin/default-featured-image/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/default-featured-image/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/default-featured-image/reviews/)

## Tags

 * [image](https://wordpress.org/support/topic-tag/image/)
 * [resize](https://wordpress.org/support/topic-tag/resize/)
 * [size](https://wordpress.org/support/topic-tag/size/)
 * [teaser](https://wordpress.org/support/topic-tag/teaser/)

 * 4 replies
 * 2 participants
 * Last reply from: [Dave Chimny](https://wordpress.org/support/users/netzblogr/)
 * Last activity: [10 years, 2 months ago](https://wordpress.org/support/topic/wrong-image-size/#post-7282854)
 * Status: resolved