I am using json_decode
on top of a GeoJSON file. All I need is to print a specific feature of the file, which has the following structure:
var GEOJSON = {
"type": "FeatureCollection",
"crs": { "type": "name", "properties": { "name": "urn:ogc:def:crs:OGC:1.3:CRS84" } },
"features": [
{ "type": "Feature", "properties": { "ID": "02", "NOME": "xxxxxxxxx", "TIPO": "xxxxxx", " }, "geometry": { "type": "Point", "coordinates": [ -90.00012544789, -47.012254699888 ] } }, (...)
I have several points with the structure shown, but how do I print a specific value on the screen?
I tried:
echo $tr->features[0]->properties->ID;
But I could not.