fixing loop paging

This commit is contained in:
Holger Könemann 2015-08-12 13:30:08 +02:00
parent e20c26d886
commit 0400c1dca4
1 changed files with 2 additions and 1 deletions

View File

@ -26,7 +26,8 @@ get_header(); ?>
<main id="main" class="site-main" role="main">
<?php
$the_query = new WP_Query( array( 'post__not_in' => get_option( 'sticky_posts' ) ) );
$paged = (get_query_var('paged')) ? get_query_var('paged') : 1;
$the_query = new WP_Query( array( 'post__not_in' => get_option( 'sticky_posts' ), 'paged' => $paged ) );
if ( $the_query->have_posts() ) : while ( $the_query->have_posts() ) : $the_query->the_post();
?>