Filters the_post_thumbnail() function. If no post thumbnail is defined, get the first image belonging to post or first image found in post content.
add_theme_support('post-thumbnails');in the functions.php file of your theme.
the_post_thumbnail($size, $attr)in the loop in your template where you want the post image to appear. For example :
Requires: 2.9 or higher
Compatible up to: 2.9.2
Last Updated: 2010-1-10
Active Installs: 600+
Got something to say? Need help?