Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.
query_posts( array ( 'post__in' => array( 5, 76, 21, 56, 3 ) ) );

I'd like to query the Loop using post__in and a set Wordpress IDs. I'd then like to run through the Loop in the exact order of the query. Does anyone know if that is possible?

share|improve this question
add comment

1 Answer 1

up vote 3 down vote accepted

Yes, using this plugin:

http://wordpress.org/extend/plugins/sort-query-by-post-in/

Also see http://core.trac.wordpress.org/ticket/13729

share|improve this answer
    
I spent all my time searching the Wordpress Codex that I didn't think to look in the plugins... Thanks! –  Andy Cook Feb 22 '11 at 2:30
    
Hoping they implement this in 3.5. Thanks! –  AlxVallejo Oct 1 '12 at 15:09
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.