Trouble with the_post_thumbnail (3 posts)

  1. Jack
    Posted 4 years ago #

    I'm using this in my functions.php file:

    add_theme_support( 'post-thumbnails' );
    add_image_size( 'logo', '90', '90', true );

    and this in my category template:

    if ( has_post_thumbnail() ) {

    and still I'm getting thumbnails that are not cropped. What goes wrong?

    Here is a link to one of those pages/thumbs: http://www.bt10.nl/bedrijven/thuiszorg/?view=posts&type=regio&regionummer=24

  2. Digital Raindrops
    Posted 4 years ago #

    Did you already have posts before you added the image size?

    WordPress will not rebuild the thumbnails retrospectivly, you will need to use a plugin, I use the Ajax Thumbnail Rebuild plugin.

    If you are still having issues re-upload and set the featured image for the posts that are not showing right.

    Looking at the linked image it is showing the original size 292 * 98 'wp-content/uploads/2012/03/SenZ.jpg', and we would expect to see a linked new image, a square cutout of the middle 'wp-content/uploads/2012/03/SenZ90x90.jpg', so it has not been cropped, was the feature image set before you added the code?



  3. Jack
    Posted 4 years ago #

    Thanks! Didn't thought about that and will try that plugin :).

Topic Closed

This topic has been closed to new replies.

About this Topic