<?php $a = json_decode('{"3":{"friend":45,"all":100},"2":{"friend":30,"all":50},"1":{"friend":25,"all":25}}'); var_dump((array) $a); $n = 3; var_dump($a->$n->friend);
You have javascript disabled. You will not be able to edit any code.