3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $o=new stdClass(); $o->name="هدایت"; echo json_encode($o,JSON_UNESCAPE_UNICODE);
based on O3Uda
Output for 7.2.0 - 7.2.6
Warning: Use of undefined constant JSON_UNESCAPE_UNICODE - assumed 'JSON_UNESCAPE_UNICODE' (this will throw an Error in a future version of PHP) in /in/cfHVQ on line 5 Warning: json_encode() expects parameter 2 to be integer, string given in /in/cfHVQ on line 5
Output for hhvm-3.15.4, 7.0.0 - 7.1.20
Notice: Use of undefined constant JSON_UNESCAPE_UNICODE - assumed 'JSON_UNESCAPE_UNICODE' in /in/cfHVQ on line 5 Warning: json_encode() expects parameter 2 to be integer, string given in /in/cfHVQ on line 5
Output for 5.6.0 - 5.6.30
Notice: Use of undefined constant JSON_UNESCAPE_UNICODE - assumed 'JSON_UNESCAPE_UNICODE' in /in/cfHVQ on line 5 Warning: json_encode() expects parameter 2 to be long, string given in /in/cfHVQ on line 5