3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $datetime1 = new DateTime(2013-05-08 10:15:15); $datetime2 = new DateTime('2013-05-07 22:05:15'); $interval = $datetime1->diff($datetime2); $elapsed = $interval->format('%y years, %m months, %a days, %h hours, %i minutes, %S seconds'); echo $elapsed;
Output for 5.4.0 - 5.4.14
Parse error: syntax error, unexpected '10' (T_LNUMBER) in /in/qAZNB on line 2
Process exited with code 255.
Output for 5.3.0 - 5.3.24
Parse error: syntax error, unexpected T_LNUMBER in /in/qAZNB on line 2
Process exited with code 255.