How to: Adding a Featured Image in WordPress

wordpress-logo-teal1. In functions.php:

add_theme_support( 'post-thumbnails' );

2. To display featured images in your theme, you need to edit your templates and add this line of code where you want to display the featured image:

3. To set custom size in functions.php:

set_post_thumbnail_size( 50, 50);

4. To add additional image sizes:

// Image size for single posts
add_image_size( ‘single-post-thumbnail’, 590, 180 );

5. Here is how to call a custom image size:

Special thanks to:



Recent Posts
  • Don

    Rafi, would you take a project like modifying existing daily deal script to accommodate some additional features like searching and multiple coupons per deal? We have not purchased script yet and your advice would be appreciated. It can be contus, smartecart or whatever… Please, let us know if you will be able to do it. Thank you.