I have following code
$array_store='maxbounty/maxBounty.json';
$test = $array_store->return[0]->entries[1]->value;
echo $test;
Here the file maxBounty.json has following format.
stdClass Object ( [return] => Array
( [0] => stdClass Object ( [entries] => Array
( [0] => stdClass Object ( [key] => LAUNCH_DATE [value] => 2017/02/10 )
[1] => stdClass Object ( [key] => COUNTRIES [value] => US )
[2] => stdClass Object ( [key] => CONTEXTUAL_TRAFFIC_ALLOWED [value] => Y )... and so on
But i am getting following error
Notice: Trying to get property of non-object in C:\wamp\www\couponcactusapis\test2.php on line 5
How can i print the value of LAUNCH_DATE , COUNTRIES and CONTEXTUAL_TRAFFIC_ALLOWED ?
Any idea please. THANKS.