Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /*
- Template Name: Blog Template
- */
- ?>
- <?php
- get_header();
- if (have_posts()) :
- while (have_posts()) :
- the_post();
- the_content();
- endwhile;
- endif;
- ?>
- <div class="container">
- <?php
- $custom_args = array(
- 'post_type'=> 'post',
- 'paged'=>$paged
- );
- $custom_blog_query = new WP_Query($custom_args);
- ?>
- <div id="primary" class="content-area">
- <main id="main" class="site-main" role="main">
- <?php
- if ($custom_blog_query->have_posts()) :
- while ($custom_blog_query->have_posts()) :
- $custom_blog_query->the_post();
- get_template_part( 'template-parts/content', get_post_format() );
- endwhile;
- endif;
- wp_reset_postdata();
- ?>
- <?php the_posts_navigation(); ?>
- </main>
- </div>
- <?php get_sidebar(); ?>
- </div>
- <?php get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement