3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php echo json_encode([]) . PHP_EOL; echo json_encode([], JSON_FORCE_OBJECT) . PHP_EOL; echo json_encode('Hello', JSON_FORCE_OBJECT) . PHP_EOL;
based on fYEN4
Output for 5.5.0 - 7.2.0
[] {} "Hello"