Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

My Thumbnails seem squished for some reason even though I copied the code from some thumbnails I have that seem to be working fine.

The code that works:

in index.php

<a href="<?php the_permalink(); ?>">
<?php the_post_thumbnail( 'category-thumb',array('title' => "")); ?>
</a>

in functions.php

//Main Thumbnail Size
if ( function_exists( 'add_image_size' ) ) {
    add_image_size( 'category-thumb', 192, 134 );
}

The thumbs above work fine, resizing the main image to 192x134 without a problem.

The code below does not work.

in sidebar.php

<li>
    <a class="sidebar-thumb" href="<?php the_permalink(); ?>"><?php the_post_thumbnail( 'sidebar-thumb',array('title' => "")); ?></a>       
    <a class="sidebar-link" href="<?php the_permalink(); ?>"><?php the_title(); ?></a>      
</li>

in functions.php

//Sidebar Thumbnail Size
if ( function_exists( 'add_image_size' ) ) {
    add_image_size( 'sidebar-thumb', 47, 47 );
}

What did I do incorrectly?

share|improve this question

1 Answer 1

up vote 1 down vote accepted

Had to regenerate all thumbnails. The name of the plugin is "regenerate thumbnails" for those that may run into a similar issue

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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