WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Hi I just started today on creating my first Wordpress Theme and I am trying to create a featured Image for each post.Aldo I have managed to acomplish that it seems that the sizes I am giving it are not taking effect.Here is my code:

   add_theme_support('post-thumbnails' , array('post'));

if(function_exists('has_post_thumbnail') && has_post_thumbnail()){

It seems that my featured images are not always set to the same size.For example if the image is smaller then what size I set it will remain the same , for big images the width is the same but for some the height is different.

What am I doing wrong here?

share|improve this question
up vote 1 down vote accepted

It's default behaviour that the images aren't scaled up. Easiest way would be to use simple CSS to scale it up.

How to scale up featured post thumbnail?

For the second part set the crop parameter of set_post_thumbnail_size to true.

set_post_thumbnail_size( 200, 120, true );


share|improve this answer

Your Answer


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.