Find this useful? Enter your email to receive occasional updates for securing PHP code.
Signing you up...
Thank you for signing up!
PHP Decode
--TEST-- Bug #80998: Missing second with inverted interval --FILE-- <?php $date = new Date..
Decoded Output download
--TEST--
Bug #80998: Missing second with inverted interval
--FILE--
<?php
$date = new DateTime('2021-04-05 14:00:00');
$interval = new DateInterval('P0DT10799S');
$interval->f = 0.999999;
$interval->invert = 1;
$date->add($interval);
$string = $date->format('Y-m-d H:i:s.u');
echo $string, "
";
?>
--EXPECT--
2021-04-05 11:00:00.000001
Did this file decode correctly?
Original Code
--TEST--
Bug #80998: Missing second with inverted interval
--FILE--
<?php
$date = new DateTime('2021-04-05 14:00:00');
$interval = new DateInterval('P0DT10799S');
$interval->f = 0.999999;
$interval->invert = 1;
$date->add($interval);
$string = $date->format('Y-m-d H:i:s.u');
echo $string, "\n";
?>
--EXPECT--
2021-04-05 11:00:00.000001
Function Calls
None |
Stats
MD5 | d2b1c538389c44f9fe6ffebb089ad381 |
Eval Count | 0 |
Decode Time | 123 ms |