I need to get all posts via the wordpress loop but i need them to be grouped by category and cronological within each category. Anyone know how I should go about this?
Thanks!
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You can use a new WP query to grab posts by category and display them chronologically from newest to oldest or otherwise. This works in the standard WP loop in a page template (or in the post/page editor if php execution is enabled), and can be used any number of times in the loop without conflicting with other queries. Change “mycategory” to your own category and change showposts=1 to the number of posts to show, or -1 to show all.
Function Reference/WP Query « WordPress Codex