[wp-testers] add_theme_support( 'post-thumbnails' )

Andrew Nacin wp at andrewnacin.com
Fri Jan 14 18:53:54 UTC 2011


On Fri, Jan 14, 2011 at 1:48 PM, Michael Preuß <micha at dynamicinternet.eu>wrote:

> hi,
>
> If add_theme_support( 'post-thumbnails' ); is missing in a theme but in the
> loop is
> <?php if ( has_post_thumbnail () ) :
>    the_post_thumbnail( 'thumbnail' );
> endif;?>
> a Fatal error is shown: *Fatal error*: Call to undefined function
> has_post_thumbnail()
>

That's by design. The functions only exist if the theme supports post
thumbnails.


More information about the wp-testers mailing list