WordPress.org

Make WordPress Core

Changeset 4346


Ignore:
Timestamp:
10/05/2006 03:12:24 AM (12 years ago)
Author:
markjaquith
Message:

fix usage of $m and return behavior in single_month_title(). fixes #3207

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/general-template.php

    r4339 r4346  
    261261    } elseif ( !empty($m) ) {
    262262        $my_year = substr($m, 0, 4);
    263         $my_month = $wp_locale->get_month($m);
    264     }
    265 
    266     if ( !empty($my_month) && $display )
    267         echo $prefix . $my_month . $prefix . $my_year;
    268     else
    269         return $monthnum;
     263        $my_month = $wp_locale->get_month(substr($m, 4, 2));
     264    }
     265
     266    if ( empty($my_month) )
     267        return false;
     268
     269    $result = $prefix . $my_month . $prefix . $my_year;
     270
     271    if ( !$display )
     272        return $result;
     273    echo $result;
    270274}
    271275
Note: See TracChangeset for help on using the changeset viewer.