Title: Query posts pagination problem
Last modified: August 19, 2016

---

# Query posts pagination problem

 *  Resolved [narkiej](https://wordpress.org/support/users/narkiej/)
 * (@narkiej)
 * [15 years, 8 months ago](https://wordpress.org/support/topic/query-posts-pagination-problem/)
 * I have added the following code to a specific category archive loop:
 *     ```
       <?php
       query_posts('cat=164, -13' . '&paged=' . get_query_var('paged'));
   
       if ( have_posts() ) : while ( have_posts() ): the_post(); ?>
       ```
   
 * Which does the Job and does hide category 13. However my issue is when you reahc
   the final page of pagination it is blank due to the discounted posts from category
   13. How can I get the pagination to update also and display only the number of
   pages of the new loop minus category 13.
 * My pagination is `<?php if(function_exists(‘wp_page_numbers’)) { wp_page_numbers();}?
   >
    `

Viewing 1 replies (of 1 total)

 *  Thread Starter [narkiej](https://wordpress.org/support/users/narkiej/)
 * (@narkiej)
 * [15 years, 8 months ago](https://wordpress.org/support/topic/query-posts-pagination-problem/#post-1683964)
 * There was a `//Reset Query
    wp_reset_query();` which I have removed, it works
   now!

Viewing 1 replies (of 1 total)

The topic ‘Query posts pagination problem’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 1 reply
 * 1 participant
 * Last reply from: [narkiej](https://wordpress.org/support/users/narkiej/)
 * Last activity: [15 years, 8 months ago](https://wordpress.org/support/topic/query-posts-pagination-problem/#post-1683964)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
