【发布时间】:2012-02-09 20:34:25
【问题描述】:
尝试将 45 个不同的点添加到地图中,但我只返回了 OVER_QUERY_LIMIT,但没有地图。
我通过字符串搜索获取位置,然后将返回的 LatLng 对象分配给新的 google Marker 对象
字符串搜索
var geocoder = new google.maps.Geocoder();
geocoder.geocode( { 'address': x}, function(results, status) {
if (status === google.maps.GeocoderStatus.OK) {
var result = results[0].geometry.location;
return result;
} else {
alert("Geocode was not successful for the following reason: " + status);
}
});
【问题讨论】:
-
code.google.com/apis/maps/documentation/javascript/usage.html> ?
-
你是如何获得字符串搜索的?
-
每天 2500 次搜索只允许进行地理编码,或者如果您执行 45 点,则 2500/45 = 55 次才会阻止您。除非你有商务版,否则你会得到 100000 code.google.com/apis/maps/documentation/geocoding
-
但它仍然让我从同一域、同一台机器上运行地图!
-
它不会阻止您使用地图,只是地理编码。
标签: javascript api google-maps google-maps-api-3 limits