mirror of
https://github.com/php/php-src.git
synced 2024-10-19 07:22:40 +00:00
4b64dbb9a1
pattern '(A|a) .+'). - MFH: Fixed bug #41844 (Format returns incorrect number of digits for negative years -0001 to -0999). - MFH: Fixed bug #41842 (Cannot create years < 0100 & negative years with date_create or new DateTime). - MFH: Fixed bug #41709 (strtotime() does not handle 00.00.0000). - MFH: Fixed bug #41523 (strtotime('0000-00-00 00:00:00') is parsed as 1999-11-30).
34 lines
531 B
PHP
34 lines
531 B
PHP
--TEST--
|
|
Bug #41709 (strtotime() does not handle 00.00.0000)
|
|
--FILE--
|
|
<?php
|
|
date_default_timezone_set("UTC");
|
|
|
|
$date_string = '00.00.0000 - 00:00:00';
|
|
print_r(date_parse($date_string));
|
|
|
|
?>
|
|
--EXPECT--
|
|
Array
|
|
(
|
|
[year] => 0
|
|
[month] => 0
|
|
[day] => 0
|
|
[hour] => 0
|
|
[minute] => 0
|
|
[second] => 0
|
|
[fraction] => 0
|
|
[warning_count] => 0
|
|
[warnings] => Array
|
|
(
|
|
)
|
|
|
|
[error_count] => 1
|
|
[errors] => Array
|
|
(
|
|
[11] => Unexpected character
|
|
)
|
|
|
|
[is_localtime] =>
|
|
)
|