Make WordPress Core


Ignore:
Timestamp:
04/22/2006 12:22:28 AM (19 years ago)
Author:
ryan
Message:

Fix backreferences in mysql2date(). Props tenpura. fixes #2564

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.0/wp-includes/functions.php

    r3744 r3745  
    3333        $dateweekday_abbrev = $weekday_abbrev[$dateweekday];
    3434        $dateformatstring = ' '.$dateformatstring;
    35         $dateformatstring = preg_replace("/([^\\\])D/", "\\1".backslashit($dateweekday_abbrev), $dateformatstring);
    36         $dateformatstring = preg_replace("/([^\\\])F/", "\\1".backslashit($datemonth), $dateformatstring);
    37         $dateformatstring = preg_replace("/([^\\\])l/", "\\1".backslashit($dateweekday), $dateformatstring);
    38         $dateformatstring = preg_replace("/([^\\\])M/", "\\1".backslashit($datemonth_abbrev), $dateformatstring);
     35        $dateformatstring = preg_replace("/([^\\\])D/", "\${1}".backslashit($dateweekday_abbrev), $dateformatstring);
     36        $dateformatstring = preg_replace("/([^\\\])F/", "\${1}".backslashit($datemonth), $dateformatstring);
     37        $dateformatstring = preg_replace("/([^\\\])l/", "\${1}".backslashit($dateweekday), $dateformatstring);
     38        $dateformatstring = preg_replace("/([^\\\])M/", "\${1}".backslashit($datemonth_abbrev), $dateformatstring);
    3939
    4040        $dateformatstring = substr($dateformatstring, 1, strlen($dateformatstring)-1);
Note: See TracChangeset for help on using the changeset viewer.