3v4l.org

run code in 300+ PHP versions simultaneously
<?php $json = '{ "data": [ { "message_count": 14051 }, { "message_count": 12731 }, { "message_count": 7867 }, { "message_count": 6053 }, { "message_count": 4 } ] }'; $json_a=json_decode($json); $counting_base = ($json_a['data']); var_dump($counting_base); echo array_sum($counting_base);
Output for git.master, git.master_jit, rfc.property-hooks
Fatal error: Uncaught Error: Cannot use object of type stdClass as array in /in/doLci:24 Stack trace: #0 {main} thrown in /in/doLci on line 24
Process exited with code 255.

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
41.61 ms | 401 KiB | 8 Q