谷歌地理编码API不如使用地址的谷歌地图准确 [英] google geocoding api not as accurate as google maps using address

查看:115
本文介绍了谷歌地理编码API不如使用地址的谷歌地图准确的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有很多例子,其中谷歌地图返回确切的位置,而地理编码找不到确切的匹配,而仅提供纬度/经度的紧密匹配,这对我的目的不利.

示例:谷歌地图中的"1729号国道8号,奥本,印第安纳州46706"将我准确地投放到沃尔玛配送中心.

使用地理编码.... http://gmaps-samples.googlecode.com/svn/trunk/geocoder /singlegeocode.html

或手动

通过解决方案

在阅读了很多答案之后,我发现此解决方案是使用 Gecoder 查找最近的邮政地址.数据使用Google Places API

https://developers.google.com/places/web-service/search#PlaceSearchRequests

可以这样做

https://maps.googleapis.com/maps/api/place/textsearch/json?query=someplacename&key=key

I have many examples where google maps returns the exact location whereas geocoding cannot find an exact match and provides only a close match lat/lon which is no good for my purpose.

example: "1729 state road 8, auburn, IN 46706" in google maps drops me exactly on a walmart distribution center as it should.

using geocoding.....either thru http://gmaps-samples.googlecode.com/svn/trunk/geocoder/singlegeocode.html

or manually

via https://maps.googleapis.com/maps/api/geocode/json?address=1729+state+road+8,+auburn,+IN,+46706&key=[your_key_here]

has the location several miles away...

I don't understand why the difference as I would expact MAPs to use geocoding etc, and many many examples don't match up between the two. I need to get geocoding via MAPS !

解决方案

After reading through lot of answers i came across this solution that Gecoder is used to find the nearest postal addresses.To get Local Business Data use Google Places API

https://developers.google.com/places/web-service/search#PlaceSearchRequests

it can be done like this

https://maps.googleapis.com/maps/api/place/textsearch/json?query=someplacename&key=key

这篇关于谷歌地理编码API不如使用地址的谷歌地图准确的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆