Forum Replies Created

Viewing 1 replies (of 1 total)
  • Forum: Plugins
    In reply to: get_the_post_thumbnail
    Thread Starter ArdorEdor42

    (@ardoredor42)

    The code above works well, but I can’t figure out how to add an if statement do essentially this:

    <?php if ( has_post_thumbnail() ) {
    the_post_thumbnail(‘thumbnail’);}

    else { ?>
    <img src=”<?php bloginfo(‘template_directory’); ?>/images/default-image.jpg” />
    <?php } ?>

Viewing 1 replies (of 1 total)