【问题标题】:Adding google maps markers by an address instead of coordinates?通过地址而不是坐标添加谷歌地图标记?
【发布时间】:2011-08-04 03:56:28
【问题描述】:

在我的 Flex 项目中,我可以通过地址而不是这个来添加标记吗:

var myGeographicCoordinates:LatLng = new LatLng(myLatitude, myLongitude);

例如通过“Paris, France”添加标记

【问题讨论】:

标签: apache-flex google-maps-api-3 geocoding street-address


【解决方案1】:

我认为你不能直接这样做。相反,您需要对地址进行地理编码,然后使用LatLng 来存储结果。

在此处查看 google 的地理编码 api:

http://code.google.com/apis/maps/documentation/geocoding/

【讨论】:

    【解决方案2】:

    您应该阅读Google's developer manual on Geocoding。它解释了如何将地址转换为地理位置。我建议您在此处发布之前尝试查看开发手册/API/Google。

    【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2018-04-02
    • 1970-01-01
    • 1970-01-01
    • 2015-09-12
    • 2018-12-09
    • 2015-08-22
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多