bdbrown

Hueman Index.php

Jan 19th, 2015
258
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.90 KB | None | 0 0
  1.         <?php if ( have_posts() ) : ?>
  2.        
  3.             <!-- if we're on a mobile device, or if we're on the main home page, don't use Standard Blog List -->
  4.             <?php $use_std_blog_list = true;
  5.                 if ( wp_is_mobile() || ( is_home() && ! is_paged() ) ) {
  6.                     $use_std_blog_list = false;
  7.                 }
  8.             ?>
  9.  
  10.             <?php if ( ot_get_option('blog-standard') == 'on' && $use_std_blog_list ): ?>
  11.                 <?php while ( have_posts() ): the_post(); ?>
  12.                     <?php get_template_part('content-standard'); ?>
  13.                 <?php endwhile; ?>
  14.             <?php else: ?>
  15.             <div class="post-list group">
  16.                 <?php $i = 1; echo '<div class="post-row">'; while ( have_posts() ): the_post(); ?>
  17.                     <?php get_template_part('content'); ?>
  18.                 <?php if($i % 2 == 0) { echo '</div><div class="post-row">'; } $i++; endwhile; echo '</div>'; ?>
  19.             </div><!--/.post-list-->
  20.             <?php endif; ?>
  21.        
  22.             <?php get_template_part('inc/pagination'); ?>
  23.            
  24.         <?php endif; ?>
Advertisement
Add Comment
Please, Sign In to add comment