Title: Need help querying  posts
Last modified: August 19, 2016

---

# Need help querying posts

 *  [KostRev](https://wordpress.org/support/users/kostrev/)
 * (@kostrev)
 * [17 years, 9 months ago](https://wordpress.org/support/topic/need-help-querying-posts/)
 * I’m incrementing my posts and would like to display the 1st, 4th, 7th, and 10th…
   post –basically every third post starting with 1.
 * My loop example checks for and displays even numbered posts:
 *     ```
       <?php
       if (have_posts()) :
       while(have_posts()) :
       $i++;
       if(($i % 2) == 0) : $wp_query->next_post();
       else : the_post();
       ?>
       ```
   
 * What should this look like:
    `if(($i % 2) == 0)`
 * Thank you for the help.

The topic ‘Need help querying posts’ is closed to new replies.

 * 0 replies
 * 1 participant
 * Last reply from: [KostRev](https://wordpress.org/support/users/kostrev/)
 * Last activity: [17 years, 9 months ago](https://wordpress.org/support/topic/need-help-querying-posts/)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
