I have a problem I am getting a json file I can echo it and it looks like this
[{"sys_data":"0MxPPaza","date":"2015-02-15","objective":"VIDEO"}]
in my code I am doing this
$json = FROM THE SERVER;
$obj = json_decode($json);
$res = $obj->["objective"];
echo $res;
res is NULL obj is NULL also
echo json_last_error_msg(). What do you get?$res = $obj->["objective"];construction.$objisnull, then the json string is not valid at all. Try to display $json. make sure it is really valid.