Title: posts missing
Last modified: August 19, 2016

---

# posts missing

 *  Resolved [fksr86](https://wordpress.org/support/users/fksr86/)
 * (@fksr86)
 * [18 years, 1 month ago](https://wordpress.org/support/topic/posts-missing/)
 * hey, everyone
 * i’m having a little problem on my website
 * on my home page, i need to exclude some categories. i’m using this with a query
   that exclude categories
 * `<?php query_posts('cat=-7,-102&showposts=15'); ?>`
 * but the `posts_nav_link` doesn’t work with this.
 * i tried a traditional loop, using `if ( in_category('7') || in_category('102'))}
   continue`, but the posts showed on the home page changes depending on how much
   posts were excluded.
 * what can i do?

Viewing 1 replies (of 1 total)

 *  Thread Starter [fksr86](https://wordpress.org/support/users/fksr86/)
 * (@fksr86)
 * [18 years, 1 month ago](https://wordpress.org/support/topic/posts-missing/#post-760074)
 * well, i’ve found a solution.
 *     ```
       <?php $paged = (get_query_var('paged')) ? get_query_var('paged') : 1;
       query_posts("cat=-7,-146&paged=$paged"); ?>
       ```
   
 * using this `$paged` thing made my `posts_nav_link` work.
 * thanks anyway!

Viewing 1 replies (of 1 total)

The topic ‘posts missing’ is closed to new replies.

## Tags

 * [category](https://wordpress.org/support/topic-tag/category/)
 * [exclude](https://wordpress.org/support/topic-tag/exclude/)
 * [home](https://wordpress.org/support/topic-tag/home/)
 * [query](https://wordpress.org/support/topic-tag/query/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 1 reply
 * 1 participant
 * Last reply from: [fksr86](https://wordpress.org/support/users/fksr86/)
 * Last activity: [18 years, 1 month ago](https://wordpress.org/support/topic/posts-missing/#post-760074)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
