How do you know that I running the same query?
I trying to do like this:
<?php
$paged = ( get_query_var( 'paged' ) ) ? get_query_var( 'paged' ) : 1;
$replys_query = new WP_Query( 'post_type=replys&posts_per_page=2&paged='.$paged );
?>
<div class="reply-items-full">
<?php
// Cycle
if ( $replys_query->have_posts() ) {
while ( $replys_query->have_posts() ) {
$replys_query->the_post();
$reply_author = get_post_meta($replys_query->post->ID,'reply_author_name');
?>
<div class="col-lg-12 reply-item-full">
<span class='reply-content-full'><?php echo get_the_content(); ?></span>
<span class="reply-author-full"><?php echo $reply_author[0]; ?></span>
</div>
<?php } ?>
<?php previous_posts_link( '« Previous' ); ?>
<?php } else {
echo "<p>there are no replys.</p>";
}
echo "</div>";
/* Return original post data. Reset $post. */
wp_reset_postdata();
but pagination still nor appears.
Do you see some problems in this code?
Thank you a lot, csloisel! 🙂