3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $json = "{ "data": [ { "message_count": 14051 }, { "message_count": 12731 }, { "message_count": 7867 }, { "message_count": 6053 }, { "message_count": 4 } ] }"; $json_a=json_decode($json,true); $counting_base = ($json_a['data']); var_dump($counting_base); echo array_sum($counting_base);
Output for 5.4.0 - 5.4.25
Parse error: syntax error, unexpected 'data' (T_STRING) in /in/c5PC6 on line 4
Process exited with code 255.
Output for 5.3.0 - 5.3.28
Parse error: syntax error, unexpected T_STRING in /in/c5PC6 on line 4
Process exited with code 255.