3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $content = '{"ORDERLIST":"{\"ORDER_LIST\":[{\"order_id\":\"1756\",\"uname\":\"jordan\",\"prod_name\":\"ABC\",\"quantity\":\"1\",\"branch\":\"Dapitan\",\"totalPrice\":\"23500\"}"]}"}'; $response = json_decode($content, true); $orderlist = json_decode($response['ORDERLIST'], true); $count = count($response); echo $count; //var_dump($response, $orderlist);
based on 9huL3
Output for 7.2.0
Warning: count(): Parameter must be an array or an object that implements Countable in /in/n7YdF on line 5 0
Output for 5.5.0 - 7.1.10
0