Answer the question
In order to leave comments, you need to log in
Why is json not being parsed?
There is an address, you need to know the coordinates. Does not work:
$content = file_get_contents("https://maps.googleapis.com/maps/api/geocode/json?address=Москва,%20ул.%20Академика%20Бочвара,%202");
$json = json_decode($content, true);
echo $json["results"]["geometry"]["location"]["lat"];
Answer the question
In order to leave comments, you need to log in
because :
and, of course, you need to check whether the response contains the required data, and then process them, if any)
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question