3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $formats = [ IntlDateFormatter::FULL, IntlDateFormatter::LONG, IntlDateFormatter::MEDIUM, IntlDateFormatter::SHORT, ]; foreach ($formats as $format) { $formatter = new IntlDateFormatter( 'en_US', $format, IntlDateFormatter::NONE, 'Europe/Moscow' ); echo $formatter->format(1455111783), PHP_EOL; }
based on Q1bYG
Output for 5.5.17, 5.6.0 - 5.6.38, hhvm-3.10.1 - 3.22.0, 7.0.0 - 7.3.1
Wednesday, February 10, 2016 February 10, 2016 Feb 10, 2016 2/10/16
Output for 5.4.0 - 5.5.16, 5.5.18 - 5.5.38
Fatal error: Class 'IntlDateFormatter' not found in /in/MMDPS on line 4
Process exited with code 255.
Output for 4.4.2 - 4.4.9, 5.1.0 - 5.3.29
Parse error: syntax error, unexpected '[' in /in/MMDPS on line 3
Process exited with code 255.
Output for 4.3.0 - 4.3.1, 4.3.5 - 4.4.1, 5.0.0 - 5.0.5
Parse error: parse error, unexpected '[' in /in/MMDPS on line 3
Process exited with code 255.
Output for 4.3.2 - 4.3.4
Parse error: parse error in /in/MMDPS on line 3
Process exited with code 255.