0

This is a weird situation. I have defined

 add_theme_support('post-thumbnails');
 add_image_size('190x280',190 , 280,true);
 add_image_size('400x600',400 , 600,true);

Uploaded images to post as featured image, on the server side I see the resized images in the uploads folder. In the template, I use code like this

<?php query_posts( 'post_type=hints&posts_per_page=1'); ?>
    <?php  if ( have_posts() ) while ( have_posts() ) : the_post(); ?>
    <div class="posrelative center-block ">
        <a class="colblack" title="<?php the_title_attribute(); ?>" href="<?php the_permalink();?>">
        <?php the_post_thumbnail('190x280', array('class' => 'img-responsive')); ?>
        <span class="textonpicleft two-lines"><?php echo get_the_title(); ?></span>
        </a>
    </div>

But, the function the_post_thumbnail returns only full sized image!

What the $#ck can it be? Because it is really annoying and I can not debug it? And this code I am using on other sites as well and everything works.

Do you know, how to debug it?

  • I assume you have tested with all plugins disabled? – s_ha_dum Mar 26 '14 at 19:05
  • Yes. No change. – jam Mar 26 '14 at 19:08
0

It is wery important, that your upload folder and subolders and images has the right permissions for webserver. If not, if you run Thumbnail regenerator plugin, something brakes and the_post_thumbnail failing to run correctly!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.