i would love to extract all values, the result what i receive now is:
{"time":1502822744114809900,"lat":48.278868,"lon":3.704626,"alt":0,"pol":0,"mds":9412,"mcg":65} {"time":1502822743755137300,"lat":48.74463,"lon":12.346999,"alt":0,"pol":0,"mds":14795,"mcg":53} {"time":1502822743719286800,"lat":48.76882,"lon":12.345279,"alt":0,"pol":0,"mds":7864,"mcg":78} {"time":1502822743574110500,"lat":48.751461,"lon":12.291977,"alt":0,"pol":0,"mds":14299,"mcg":84} {"time":1502822743531312600,"lat":46.732674,"lon":12.635411,"alt":0,"pol":0,"mds":8500,"mcg":98} {"time":1502822743430266600,"lat":46.787249,"lon":12.645081,"alt":0,"pol":0,"mds":10899,"mcg":126} {"time":1502822743361762600,"lat":46.75697,"lon":12.664295,"alt":0,"pol":0,"mds":8831,"mcg":135} {"time":1502822743317798700,"lat":50.373524,"lon":5.757353,"alt":0,"pol":0,"mds":7804,"mcg":61} {"time":1502822743103383600,"lat":50.359257,"lon":5.767865,"alt":0,"pol":0,"mds":11733,"mcg":248} {"time":1502822743075182600,"lat":48.814166,"lon":12.446773,"alt":0,"pol":0,"mds":14876,"mcg":119}
I want to have every lat and lon coordinate and time value
i already tried with:
Code: Select all
$bliksems=file_get_contents('http://blablabla');
foreach($bliksems as $bliksem){
$lat=$bliksems['lat'];
lg($lat);
}
the answer i'm getting from $bliksems is not a real json it seems (i guess because the layout is different)
can someone help me or just guide me in the correct way, thank you.