#45359 [Opn->Bgs]: strtotime: negative timestamps var_dump(strtotime('1214431948'));
| From: | derick@php.net | Date: | Wed, 25 Jun 2008 21:06:59 +0000 |
| Subject: | #45359 [Opn->Bgs]: strtotime: negative timestamps var_dump(strtotime('1214431948')); | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-126028@lists.php.net to get a copy of this message | ||
ID: 45359
Updated by: derick@php.net
Reported By: ovidiu dot leferman at gmail dot com
-Status: Open
+Status: Bogus
Bug Type: Date/time related
Operating System: Vista Ultimate 32B Sp1
PHP Version: 5.2.6
New Comment:
THis is not a bug, it simply parses this as "12:13:43 1948"):
derick@kossu:~$ php -r 'var_dump(date_parse("1214431944"));'
array(12) {
["year"]=>
int(1944)
["month"]=>
bool(false)
["day"]=>
bool(false)
["hour"]=>
int(12)
["minute"]=>
int(14)
["second"]=>
int(43)
["fraction"]=>
float(0)
["warning_count"]=>
int(0)
["warnings"]=>
array(0) {
}
["error_count"]=>
int(0)
["errors"]=>
array(0) {
}
["is_localtime"]=>
bool(false)
}
Previous Comments:
------------------------------------------------------------------------
[2008-06-25 20:03:19] ovidiu dot leferman at gmail dot com
Description:
------------
var_dump(strtotime('1214431944'));
returning int(-805297517)
Reproduce code:
---------------
var_dump(strtotime('1214431944'));
Expected result:
----------------
false / -1
Actual result:
--------------
int(-805297517)
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=45359&edit=1