[wp-hackers] wp_reset_query() (was Complete list of articles)

Stephen Rider wp-hackers at striderweb.com
Mon Feb 4 22:23:55 GMT 2008


On Feb 4, 2008, at 2:22 PM, Pixline wrote:

>> query_posts($query_string.'posts_per_page=-1');
>> while(have_posts()) { the_post();
>> the_time();
>> the_title();
>> }
>>
>> If you want to make the thing paged, just change the posts_per_page
>> number to how many you want to show on each page, then add some next
>> and previous link calls to make it paged.
>
> This should be in the codex. It's one of the clearest examples I've  
> ever read.
> I'm just undecided on where to put it :-)

Is there any consensus as to whether people should be using  
wp_reset_query() at the end of custom query_posts() loops?

http://trac.wordpress.org/ticket/4741

The function seems to be a really good idea, and it _is_ implemented  
-- but nobody seems to actually use it....

Stephen


-- 
Stephen Rider
<http://striderweb.com/>




More information about the wp-hackers mailing list