• Resolved carloravelli

    (@carloravelli)


    I’m running a wordpress site for a client and he recently came up with a problem with the pagination: When you go to the second page of his blog, it shows exactly the same posts as the first page, when it should display older posts.

    I tried using 2 different pagination types (wp_pagenavi and twentyeleven) but they both get the same thing.

    What could I be doing wrong?

    This is what my archive.php looks like:

    <?php get_header(); ?>
    <div class="content">
    		<h1><?php single_cat_title(); ?></h1>
    		<?php $currentCat = get_query_var('cat'); ?>
    <?php
    if(cat_is_ancestor_of(3, $currentCat)) {
    } else {
    	// The Query
    	query_posts( 'cat=-34,-35,-6,' );
    }
    
    // The Loop
    while ( have_posts() ) : the_post(); ?>
    
    --- the post html ---
    
    <?php endwhile;
    
    // Reset Query
    wp_reset_query();
    ?>
    </div>
    <?php wp_pagenavi(); ?>
    <?php get_footer(); ?>

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Pagination disfunction – Pages show the same posts’ is closed to new replies.