Im trying the echo the elevation of an address in PHP. I am using the Google Elevation API - LINK
I already have the latitude and longitude. The following link:
https://maps.googleapis.com/maps/api/elevation/json?locations=40.7143528,-74.0059731&key=myapikey
will produce these results in json:
{
"results" : [
{
"elevation" : 9.774918556213379,
"location" : {
"lat" : 40.7143528,
"lng" : -74.00597310000001
},
"resolution" : 19.08790397644043
}
],
"status" : "OK"
}
How can I echo the elevation?
something like <?php echo 'elevation'; ?>
Thank you