• Up until recently my blog has been displaying fine, as I wanted it, ordering the posts by post_date descending.
    Today (may have been earlier since I don’t visit it every day) it started displaying the posts in ascending order by post_date. What happened?

    I have looked everywhere in the Admin login and find no control over how the posts are ordered for display!

    My blog is ourholm.com-slash-blog

Viewing 2 replies - 16 through 17 (of 17 total)
  • … I found this Plugin which fixed the problem on my blog:

    <?php
    /*
    Plugin Name: 123 No Group By ID
    Plugin URI:
    Description: Changes the GROUP BY id in GROUP BY post_date (Problem from MySQL 5.0.51).
    Author: Ingo Henze
    Version: 0.10
    Author URI: https://putzlowitsch.de/
    */ 
    
        // GROUP BY auswerten
        function plw123ngb_posts_groupby( $groupby ) {
            if( preg_match( "/(|[ ,.])id(|[ ,])/i", $groupby ) )
                $groupby = 'post_date';
            return $groupby;
        }
    
        add_filter( 'posts_groupby', 'plw123ngb_posts_groupby' );
    
    ?>

    To follow up on this, there was a report that this problem is caused when hosts upgrade to MySQL version 5.0.51. The problem, a MySQL bug, is fixed in MySQL 5.0.52.

    For more info see Peter Westwood’s post on wp-hackers:
    https://comox.textdrive.com/pipermail/wp-hackers/2008-January/017200.html

Viewing 2 replies - 16 through 17 (of 17 total)
  • The topic ‘How Do I Fix The Sort Order Of My Posts?’ is closed to new replies.