Ok i’m stuck here
i have a json output given from the code above
$jsonurl = 'http://us.battle.net/api/d3/profile/'.$btag.'/';
$json = file_get_contents($jsonurl,0,null,null);
$json_output = json_decode($json);
i can retrieve the data using, for example
$json_output->code
but, i have a specific data i need to retrieve
$json_output->timePlayed->demon-hunter
this one i cant retrieve because of the “-” in side the “demon-hunter” any tips?
Yeah, either use arrays:
Or use the following notation: