Home › Forums › Back End › Placing Recent Posts on Responsive Theme Stock Homepage › Reply To: Placing Recent Posts on Responsive Theme Stock Homepage
May 4, 2014 at 1:26 pm
#169197
bmoneruiux
Participant
Ok so managed to cut the code down even more, but still having trouble only displaying the recent 3 posts that have a featured image. The updated code:
<?php while( have_posts() ) : the_post(); ?>
<?php responsive_entry_before(); ?>
<div id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
<?php responsive_entry_top(); ?>
<?php get_template_part( 'post-meta-page' ); ?>
<div class="post-entry">
<?php if( has_post_thumbnail() ) : ?>
<a href="<?php the_permalink(); ?>" title="<?php the_title_attribute(); ?>">
<?php the_post_thumbnail(); ?>
</a>
<?php endif; ?>
</div>
<?php get_template_part( 'post-data' ); ?>
<?php responsive_entry_bottom(); ?>
</div><!-- end of #post-<?php the_ID(); ?> -->
<?php responsive_entry_after(); ?>
<?php
endwhile;
?>