Remove PHP 5.1/Windows code from date_i18n. Allows timestamps from pre-1970. props DH-Shredder, fixes #10332.

git-svn-id: https://develop.svn.wordpress.org/trunk@17747 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Nacin 2011-04-28 15:13:30 +00:00
parent 4259cd6a27
commit 1f4d59925e
1 changed files with 0 additions and 10 deletions

View File

@ -84,16 +84,6 @@ function current_time( $type, $gmt = 0 ) {
function date_i18n( $dateformatstring, $unixtimestamp = false, $gmt = false ) {
global $wp_locale;
$i = $unixtimestamp;
// Sanity check for PHP 5.1.0-
if ( false === $i || intval($i) < 0 ) {
if ( ! $gmt )
$i = current_time( 'timestamp' );
else
$i = time();
// we should not let date() interfere with our
// specially computed timestamp
$gmt = true;
}
// store original value for language with untypical grammars
// see http://core.trac.wordpress.org/ticket/9396