having problems using the text concatenation with the '->' operator in PHP.
I cant seem to get the syntax right for $playerArray[$x] = $players->$p . $x;
all this code should do is step through the 'Players' JSON object and return the values from players 1 - 15
$playerArray = array();
$p = "Player_";
for ($x = 0; $x < 15; $x++) {
$playerArray[$x] = $players->$p . $x;
// insert into database the above
}
Here is the json object im trying to get values from.