0
我使用谷歌地圖API,它適用於除一個特定地址以外的所有地址。這是「99p商店19-20市場Wisbech PE13 1DZ」。當使用谷歌地圖我可以找到它,但使用js api它說'零結果'。谷歌地圖API找不到一個特定的地址
我的代碼:
function mapsSetMark(map, address) {
var geocoder = new google.maps.Geocoder();
geocoder.geocode({'address': address}, function (results, status) {
if (status === google.maps.GeocoderStatus.OK) {
map.setZoom(13);
map.setCenter(results[0].geometry.location);
var marker = new google.maps.Marker({
map: map,
position: results[0].geometry.location
});
} else {
console.log('Geocode was not successful for the following reason: ' + status);
}
});
}