[Solved] Loop data from query

Your json_decode() has a second parameter which determine the return type. By default, it will parse the JSON string into stdObject, while you access it using indexes which is wrong $server = Json_Decode(File_Get_Contents(“http://query.fakaheda.eu/”)); foreach($server->players_list as $player) { echo ‘<span class=”ipsGrid_span4″>’.$player->name.'</span>’; echo ‘<span class=”ipsGrid_span4″>’.$player->score.'</span>’; echo ‘<span class=”ipsGrid_span4″>’.$player->time.'</span>’; } To parse json string into array, use json_encode($jsonString, … Read more