I am trying to change the ordering of the comments on my WordPress blog, so that it will show the newest comment on top. I tried it in the settings, but it didn't take effect...
I am trying to change the ordering of the comments on my WordPress blog, so that it will show the newest comment on top. I tried it in the settings, but it didn't take effect...
find the file that handles showing comments and alter the mysql query to order it by the timestamp in descending order (DESC)
Are you using a system such as WP-SuperCache?
This cache's your blog's info for faster loading times, but changes may not show until the cache is deleted and recreated.
█ Neil Hanlon | x10Hosting Support Representative
█ Neil[at]x10hosting.com
█ I'm always happy to help. Just ask a question in Free Hosting
█ Terms of Service IRC
Inside wp-includes/comment.php you can find the function "get_comments" and the SQL request: "SELECT * FROM $wpdb->comments WHERE $post_where $approved ORDER BY $orderby $order $number". $orderby is a parameter of this function and since WordPress 2.7 you can set the sort order in the admin panel, where I set it correctly.
Yes I am using SuperCache. But eben when I disable it the comments are still in the wrong order...