我正在使用Google Map GeoCoder v3(JSON)来获取
的坐标Praia do forte
Mata de São João, Bahia
Brazil
Google Geocoder API 无法找到它,但http://maps.google.com 可以找到它。
这是Google Maps API v3 请求我想要进行地理编码的网址
这是回复。
{
"results" : [
{
"address_components" : [
{
"long_name" : "Praia",
"short_name" : "Praia",
"types" : [ "locality", "political" ]
},
{
"long_name" : "Praia",
"short_name" : "Praia",
"types" : [ "administrative_area_level_1", "political" ]
},
{
"long_name" : "Cape Verde",
"short_name" : "CV",
"types" : [ "country", "political" ]
}
],
"formatted_address" : "Praia, Cape Verde",
"geometry" : {
"bounds" : {
"northeast" : {
"lat" : 14.97272960,
"lng" : -23.47061630
},
"southwest" : {
"lat" : 14.90016530,
"lng" : -23.54284290
}
},
"location" : {
"lat" : 14.9304640,
"lng" : -23.5126690
},
"location_type" : "APPROXIMATE",
"viewport" : {
"northeast" : {
"lat" : 14.95202550,
"lng" : -23.48065420
},
"southwest" : {
"lat" : 14.90890030,
"lng" : -23.54468380
}
}
},
"types" : [ "locality", "political" ]
}
],
"status" : "OK"
}
这显然是在佛得角的一个城市“Praia”这个词上绊倒。
答案 0 :(得分:0)
API地理编码器与地图地理编码器不同(请参阅API文档中的常见问题解答)。
但是,提供 足够的信息来识别该地点的工作原理: http://maps.googleapis.com/maps/api/geocode/json?sensor=false&address=Praia+do+forte,Brazil