3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php echo (new \DateTime())->format('Y-m-d H:i:s w');
based on EABlV
Output for 5.4.0 - 7.1.11, 7.1.13 - 7.3.1
2015-09-17 09:46:31 4
Output for 7.1.12
2015-09-17 09:46:32 4
Output for 5.3.18 - 5.3.29
Parse error: syntax error, unexpected T_OBJECT_OPERATOR, expecting ',' or ';' in /in/X0VTF on line 2
Process exited with code 255.