如何针对用户输入的一些不完整的地址获取地址建议?

发布于 2024-11-01 18:52:32 字数 1539 浏览 8 评论 0原文

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

你是我的挚爱i 2024-11-08 18:52:32

您可以查看 Google 的地理编码 api。这些使您能够输入地址、地址的一部分或坐标,并返回周围的地点或类似的地点,您可以将其用作建议。

You can take a look at the Google's geocoding apis. These enable you to enter address, part of address or co-ordinates and return places around or similar places that you can use as suggestions.

风柔一江水 2024-11-08 18:52:32

有许多商业库可以进行“地址标准化”。他们下载美国邮政服务地址数据库。它使他们能够标准化地址并验证街道确实存在。

There are a number of libraries commercially available that do "Address normalization". They download the US postal service address database. It allows them to standardize the address and validate that the street really exists.

公布 2024-11-08 18:52:32

Dixie,我在一家名为 SmartyStreets 的公司工作——我们从事地址验证行业。 Jay 是对的:有很多服务可以满足您的要求,但只有少数是准确的并经过政府机构认证的。

我意识到您在欧洲需要这项服务,尽管我不知道这些国家/地区邮政当局的运作方式,但原则是相同的:许可证限制适用于免费服务(请参阅上面我的评论),并且您将需要找到一个被批准用于自动查询的工具。

另外,请注意地址近似与地址验证。前者不保证地址存在(这就像 Google 或 Bing)。后者肯定存在,因为它是根据政府提供的官方数据库进行处理的,并且该软件经过认证是准确的。对于此类公司/服务的模型,请尝试查看SmartyStreets,看看您在欧洲需要什么。就我们而言,我们获得了 USPS(监管邮件的政府机构)的 CASS 认证。你想要欧洲的同等水平。

更新:SmartyStreets 现在进行国际地址验证。

Dixie, I work for a company called SmartyStreets -- we're in the address validation industry. Jay is right: there are many services which will do what you require, but only a few are accurate and certified by government institutions.

I realize you need this service for Europe, and even though I don't know the workings of the post authorities for those countries, the principles are the same: license restrictions apply (see my comment above) to free services, and you'll need to find one that is approved for use for automated queries.

Also, beware of address approximation vs. address verification. The former doesn't guarantee the address exists (this is like Google or Bing). The latter is guaranteed to exist because it's being processed against an official government-provided database and the software is certified to be accurate. For a model of this type of company/service, try looking at SmartyStreets to see what you need for Europe. In our case, we're CASS-Certified by the USPS, the government agency that regulates mail. You want the equivalent for Europe.

Update: SmartyStreets now does international address verification.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文