3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $json = '{ "queueType" : "send" , "payload" : ["post",{"template":"CS - Credit Granted","email":"cgomes+mktotest-userregiste@learnvest.com","vars":{"amount":"$100.00","userId":345144147,"firstName":"Grace"},"options":[]}]}'; $b = json_decode($json); print_r(b); list($method, $paylod) = $b; print_r($method); print_r($paylod);
based on 154ob
Output for 7.2.0 - 7.3.0beta1
Warning: Use of undefined constant b - assumed 'b' (this will throw an Error in a future version of PHP) in /in/Vg6bj on line 6 b Fatal error: Uncaught Error: Cannot use object of type stdClass as array in /in/Vg6bj:8 Stack trace: #0 {main} thrown in /in/Vg6bj on line 8
Process exited with code 255.
Output for 7.0.0 - 7.1.20
Notice: Use of undefined constant b - assumed 'b' in /in/Vg6bj on line 6 b Fatal error: Uncaught Error: Cannot use object of type stdClass as array in /in/Vg6bj:8 Stack trace: #0 {main} thrown in /in/Vg6bj on line 8
Process exited with code 255.
Output for 5.6.0 - 5.6.28
Notice: Use of undefined constant b - assumed 'b' in /in/Vg6bj on line 6 b Fatal error: Cannot use object of type stdClass as array in /in/Vg6bj on line 8
Process exited with code 255.