【发布时间】:2013-08-14 11:06:22
【问题描述】:
https://maps.googleapis.com/maps/api/geocode/json?components=postal_code:01133&sensor=false 预期 - 返回 country=US, "formatted_address" : "Springfield.."
实际 - 返回 country=LT, "formatted_address" : "Vilnius 的结果01133, 立陶宛"https://maps.googleapis.com/maps/api/geocode/json?components=postal_code:07477&sensor=false 预期 - 返回 country=US, "formatted_address" : "Wayne, New Jersey.."的结果
实际 - NO_RESULTS
需要做什么才能通过美国邮政编码查询并获得美国地址组件作为响应?
【问题讨论】:
-
问题是……?
-
问题是在通过美国邮政编码查询 google geo coder api 时还需要做什么才能获得美国的有效结果。
-
好吧,你传入邮政编码 01133,然后你得到一个邮政编码 01133。在立陶宛,是的,但他们也有邮政编码 01133。谷歌没有水晶球,他们怎么会猜到你的意思是美国的邮政编码 01133?
-
同意。至少响应可以包含所有匹配国家/地区的地址组件。一个用于 LT,另一个用于美国。事实并非如此。而且路过国家:美国元件过滤也不行。