3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php echo date('H:i:s Y-m-d',strtotime("midnight today")); echo "[" . new DateTime("2015-11-05 16:00:00") - new DateTime("midnight today") . "]\n"; echo "[" . new DateTime("2015-11-04 16:00:00") < new DateTime("midnight today") . "]\n";
based on 3MZ3m
Output for 7.1.0 - 7.2.0
00:00:00 2015-11-05 Recoverable fatal error: Object of class DateTime could not be converted to string in /in/oEpXK on line 4
Process exited with code 255.
Output for 5.5.0 - 7.0.20
00:00:00 2015-11-05 Catchable fatal error: Object of class DateTime could not be converted to string in /in/oEpXK on line 4
Process exited with code 255.