Title: query posts
Last modified: August 18, 2016

---

# query posts

 *  [Root](https://wordpress.org/support/users/root/)
 * (@root)
 * [21 years, 6 months ago](https://wordpress.org/support/topic/query-posts/)
 * Does anyone happen to know where an expo on query_posts is to be found please.
   On Codex it is descibed as coming shortly. (1.5).

Viewing 6 replies - 31 through 36 (of 36 total)

[←](https://wordpress.org/support/topic/query-posts/page/2/?output_format=md) [1](https://wordpress.org/support/topic/query-posts/?output_format=md)
[2](https://wordpress.org/support/topic/query-posts/page/2/?output_format=md) 3

 *  Thread Starter [Root](https://wordpress.org/support/users/root/)
 * (@root)
 * [21 years, 5 months ago](https://wordpress.org/support/topic/query-posts/page/3/#post-179029)
 * My query ends with the endwhile you have. No php end like yours. Then into the
   loop.
 *  [chrisgalfi](https://wordpress.org/support/users/chrisgalfi/)
 * (@chrisgalfi)
 * [21 years, 5 months ago](https://wordpress.org/support/topic/query-posts/page/3/#post-179030)
 * > My query ends with the endwhile you have. No php end like yours. Then into 
   > the loop.
 * Sorry, I’m a little confused about what you’re trying to say. If you’re referring
   to the code `<?php } ?>` at the end, it belongs to the `if(is_home())`.
 *  Thread Starter [Root](https://wordpress.org/support/users/root/)
 * (@root)
 * [21 years, 5 months ago](https://wordpress.org/support/topic/query-posts/page/3/#post-179031)
 * Well I am struggling here. I scarcely understand it myself. Sorry.
 *  [davidchait](https://wordpress.org/support/users/davidchait/)
 * (@davidchait)
 * [21 years, 5 months ago](https://wordpress.org/support/topic/query-posts/page/3/#post-179032)
 * chris:
 * By ‘sticky’ Root meant ‘a post that stays at the top of the post list’. My CG-
   PostOrder plugin can ‘reorder’ the normal post list and force a particular post(
   or posts) to remain at the start of the list. “Sticky” is what most forum systems
   call such a post that remains at the head. The Adhesive plugin is similar to 
   my PostOrder plugin, though PostOrder was designed to allow multiple ‘levels’
   of priority/ordering (thus “post order”).
 * I might suffice for your needs, whereas adding a secondary loop complicates things
   a bit — in my opinion at least.
 *  [chrisgalfi](https://wordpress.org/support/users/chrisgalfi/)
 * (@chrisgalfi)
 * [21 years, 5 months ago](https://wordpress.org/support/topic/query-posts/page/3/#post-179033)
 * I was wondering if Root was referring to a sticky, like a forum sticky. Unfortunately,
   I need something that looks more like a Page and separates itself from the posts.
 * I agree adding a second loop complicates things, and it appears to be because
   the query object is not reusable. I’m still digging into WP and learning, but
   I plan on recommending this to the WP developers.
 *  [davidchait](https://wordpress.org/support/users/davidchait/)
 * (@davidchait)
 * [21 years, 5 months ago](https://wordpress.org/support/topic/query-posts/page/3/#post-179034)
 * I don’t understand what you said:
    ” I need something that looks more like a 
   Page and separates itself from the posts. “
 * ‘looks more like a Page’
    Pages are html/css just like any other post. Granted,
   depending on your theme they may be much different base templates. But you can
   style stuff all you want, with minor tricks (an extra DIV wrapping the posts 
   you care about gives you all the power in the world…).
 * ‘separates itself from the posts’
    CG-PostOrder does that, effectively, by putting
   tagged posts ‘at the top of the list’. Like a forum sticky, yes.
 * CG-PostOrder also inserts its own variable into the $post structure, so you can
   test (and do optional stuff) for Ordered posts. for instance:
 * `
    // inside start of post loop if (isset($post->postorder)) echo '<div class
   ="sticky">'; ... ... do normal post-loop output ... ... if (isset($post->postorder))
   echo '</div>';
 * Then, you can do custom CSS using:
    `.sticky {..}`
 * -d

Viewing 6 replies - 31 through 36 (of 36 total)

[←](https://wordpress.org/support/topic/query-posts/page/2/?output_format=md) [1](https://wordpress.org/support/topic/query-posts/?output_format=md)
[2](https://wordpress.org/support/topic/query-posts/page/2/?output_format=md) 3

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

## Tags

 * [query_posts](https://wordpress.org/support/topic-tag/query_posts/)

 * 36 replies
 * 8 participants
 * Last reply from: [davidchait](https://wordpress.org/support/users/davidchait/)
 * Last activity: [21 years, 5 months ago](https://wordpress.org/support/topic/query-posts/page/3/#post-179034)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
