Make WordPress Core

Ticket #34968: 34968.patch

File 34968.patch, 719 bytes (added by rommelxcastro, 9 years ago)

define order by on redirect_guess_404_permalink

  • wp-includes/canonical.php

    IDEA additional info:
    Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
    <+>UTF-8
     
    587587                if ( get_query_var('day') )
    588588                        $where .= $wpdb->prepare(" AND DAYOFMONTH(post_date) = %d", get_query_var('day'));
    589589
    590                 $post_id = $wpdb->get_var("SELECT ID FROM $wpdb->posts WHERE $where AND post_status = 'publish'");
     590                $post_id = $wpdb->get_var("SELECT ID FROM $wpdb->posts WHERE $where AND post_status = 'publish' ORDER BY post_name ASC");
    591591                if ( ! $post_id )
    592592                        return false;
    593593                if ( get_query_var( 'feed' ) )