How To: Set Featured Image w/ Custom Post Types?
-
Hey All..
I have a page called Recipes and set a featured image for that page (using it as a header). I created a custom post type to add recipes. The header image comes up fine for the page, but once I click on the individual post type, it resets to the default header image (as it should).
Right now in header I have
<?php if(has_post_thumbnail()){ echo '<div class="art-header-jpeg-without-image">'; the_post_thumbnail('full'); echo '</div>'; } else { ?> <img src="<?php bloginfo( 'template_url' ); ?>/images/slider-1.jpg" alt="Slider" title="Slider" /> <?php } ?>
But I’m not sure how to set the featured image for the single page.
- The topic ‘How To: Set Featured Image w/ Custom Post Types?’ is closed to new replies.