[SOLVED] Order Posts by Modified Date
Hi guys,
I'm hoping someone can point me in the right direction for editing the loop in the Atahualpa theme :) I'd like to order ALL the posts on my blog - www.ddwt.co.uk - by date modified order, but can't find the relevant code in the loop (or the loop for that matter!) to add the 'orderby=modified' code to. I'm using WP 2.8.4 and Atahualpa 3.4.1 Can someone help me please? Thank you :) |
The code you are looking for is in the WordPress base code. While Atahualpa does set up some of the SQL selects (populat posts, popular in category), it relies on the normal 'loop' code in WordPress to retrieve posts.
You will have to look into the Wordpress code - you can search for 'FROM $wpdb->posts' - to find the code that does the select and change the 'order by'. You also might try looking to see if there is a plugin that which will change the order |
Hi Juggledad,
Thanks for the prompt reply :) I tried as you suggested, but couldn't find the 'FROM $wpdb->posts' string anywhere unfortunately. Isn't there any way of doctoring this bit: PHP Code:
PHP Code:
|
Yay - I finally got it to work :)
So just for the sake of completeness, here's the solution (to my original request). Simply place this code: PHP Code:
PHP Code:
|
All times are GMT -6. The time now is 12:16 PM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.