WordPress Snippet: Complete List of Posts

If you're new here, you may want to subscribe to my RSS feed. One advantage of subscribing to RSS feeds is that you don't have to constantly re-visit this site to check for updates within specific sections you might be interested in because your browser or Feed reader will do this for you automatically on a regular basis plus you can even get email notification. Thanks for visiting!


[View FULL Article]
query_posts($query_string.'posts_per_page=-1');

while(have_posts()) {
the_post();

the_time();
the_title();
}


This will display the time and title for all your posts. This could result in a very long page, and a more usable way of doing it would be to change the posts_per_page parameter, and add Next and Previous links to navigate the whole list. Code snippet by Otto in the wp-hackers mailing list.




Article copyright BookOfTips.Blogspot.Com - Find helpful tips that can help you with your daily activities. All rights reserved. No part of an article may be reproduced without the prior permission.




WordPress Snippet: Complete List of Posts - Related Tips / Tricks / Hacks



If you enjoyed this post Subscribe to our feed

No Comment

Post a Comment