Skip to content

Instantly share code, notes, and snippets.

@JordanNZ
Created May 11, 2018 03:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save JordanNZ/52c83902dfbec62c7826dfffe52201d0 to your computer and use it in GitHub Desktop.
Save JordanNZ/52c83902dfbec62c7826dfffe52201d0 to your computer and use it in GitHub Desktop.
<?php
if ( have_posts() ) :
$i = 0;
?>
<div id="primary" class="content-area">
<main id="main" class="site-main" role="main">
<section class="row posts-loop <?php if ('grid' == $blog_layout) { echo esc_attr('flex-row'); } ?>"
<?php /* Start the Loop */
while ( have_posts() ) : the_post();
if ( $i == 0 && ! is_paged() ) {
?>
<div class="post-wrapper <?php echo $post_column; ?>">
<?php get_template_part( 'template-parts/post/content', $post_template ); ?>
</div>
<?php
} else {
get_template_part( 'template-parts/post/content', 'none' );
}
$i++;
endwhile;
?>
</section>
<?php the_posts_navigation(); ?>
</main><!-- #main -->
</div><!-- #primary -->
<?php endif; ?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment