- Output for 5.3.0 - 5.3.27, 5.4.0 - 5.4.22, 5.5.0 - 5.5.6
- Parse error: syntax error, unexpected ',' in /in/pHulJ on line 6
Process exited with code 255.
<?php
$now = new DateTime('now');
$date = DateTime::createFromFormat('YmdHis', '2004' . $now->format('md') . '235959');
print($now, $date);
die;
$diff = $date->diff($now, true);
printf(
'Got %s and expected %s',
$now->sub($diff)->format(DateTime::ISO8601),
$date->format(DateTime::ISO8601)
);