我有一个当前正在使用谷歌地图 API 的应用程序。我更喜欢这些 map ,我觉得你有更多的谷歌地图选择。问题是,当我给它一个 map 地址时,谷歌地图非常不准确,而 Bing 到目前为止是 100%。我也喜欢 Bings Birds Eye View ,但这并不重要。我的问题是,我能否使用 Bing API 获取我提供的地址,返回经度和纬度,然后将其提供给我现有的 Google map 以绘制该点。如果是这样,如何?我查看了 Bing map ,但找不到对地址进行地理编码的好方法。下面是我当前的谷歌地图代码
var map;
var directionsPanel;
var directions;
function initialize() {
map = new GMap(document.getElementById("map_canvas"));
map.setCenter(new GLatLng(41.1255275,-73.6964801), 15);
directionsPanel = document.getElementById("route");
directions = new GDirections(map, directionsPanel);
directions.load("from: ADDRESS 1 to: ADDRESS 2 ");
map.addControl(new GSmallMapControl());
map.addControl(new GMapTypeControl());
}
我想用Bing获取的经纬度替换ADDRESS 2
最佳答案
正如 Matt Phillips 建议的那样,您应该阅读服务条款:http://www.microsoft.com/maps/product/terms.html
合并不同的 map 服务有一个限制:
Restrictions on your use: We do have some restrictions on your use of the service. You may not:
...
- integrate the Bing Maps Platform or any of its content with any other mapping platform;
Google 的服务条款也非常严格,我想他们也会有类似的限制。
关于google-maps-api-3 - 使用 Bing 进行地理编码和 Google map API 来显示 map ,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4168896/