Make WordPress Core

Changeset 3632


Ignore:
Timestamp:
03/07/2006 09:00:38 PM (19 years ago)
Author:
ryan
Message:

Pad post_date elements. Props: masquerade. fixes #2542

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/admin-functions.php

    r3586 r3632  
    7676        $mn = ($mn > 59) ? $mn -60 : $mn;
    7777        $ss = ($ss > 59) ? $ss -60 : $ss;
    78         $_POST['post_date'] = "$aa-$mm-$jj $hh:$mn:$ss";
    79         $_POST['post_date_gmt'] = get_gmt_from_date("$aa-$mm-$jj $hh:$mn:$ss");
     78        $_POST['post_date'] = sprintf("%04d-%02d-%02d %02d:%02d:%02d", $aa, $mm, $jj, $hh, $mn, $ss);
     79        $_POST['post_date_gmt'] = get_gmt_from_date($_POST['post_date']);
    8080    }
    8181
Note: See TracChangeset for help on using the changeset viewer.