Ideal: As you type an address into the fields it'd be checked against some database and an "verified" indicator would turn on when you've completed the address correctly. Nearest matches would also be displayed.

Functional: A "verify" address link would be associated w/ each address and could be clicked to mark that address verified. This should only have to be done once for each address and then it'd be saved as verified.

Basic: A "verify address" link would plug the address into some outside website/database where you can check the address.

I don't know anything about coding or how possible this is.

Here's a website that can verify street addresses in the US. There's also a link for Canadian addresses:

http://www.melissadata.com/Lookups/addressverify.asp

Comments

yesct’s picture

If this is done, most likely the field would be displayed in reverse order from what we are used to: country, zip, street. Because depending on the country, the next thing to know will be different, for the USA it would be zip or maybe state/city. For other countries the next thing to know might be city or some other code other than zip. I think AJax (?) could be used to only display the rest of the form after the previous pieces of information are known.

yesct’s picture

Issue tags: +location validation

Tagging.

gravspeed’s picture

this is a much needed feature for me... has anyone figured out how to do this? i'm thinking the google map api should be able to tell if a search was definitive. this should function as a part of the form validator...

ankur’s picture

This would probably be best implemented as a separate module that performs the verification through the use of hook_form_alter().

We'd probably want this configurable so that verification only happens where the site admin really needs it. It would be good to implement this in a stand-alone way, so that it could be re-used in other places where locations are input but not necessarily through form fields provided by the location module.

-Ankur

vmi’s picture

What about incorporating something like this? It's free...
https://webgis.usc.edu/Services/AddressValidation/Default.aspx

All they ask for is a link back in return which shouldn't be a big deal to put something discreet underneath that says verified by.

jasonawant’s picture

Hi,

We have implemented something similar to this for a client using a 3rd party subscription service for US addresses. We created a module that validates the address on form submission using a SOAP message. If corrections are provided, we update the address. If an error returns, we present the error to the user and store the error code in a cck field for site admins. On the second form submission, we don't validate.

It's possible, but probably as an another contributed module I imagine.

jwant

MBfromOK’s picture

Project: Location » Commerce Core
Version: 6.x-3.x-dev » 7.x-1.8
Component: Miscellaneous » Customer

I own a business that is still getting off the ground and I have been granted full access to the USPS api production server after only a short delay and assuring them that 1. we intended to ship using their service (at our customer's discretion) and 2. that we would only be using the validation for customer shipments.

At the time I was attempting to use another cart system (it had a bad tax calculation flaw that made us walk away) that had a module built that simply required the username and other details that the USPS requires for access and seemed to work flawlessly.

I would like to implement this service on my new Drupal Site ASAP, but I have no idea how... I would heartily welcome any input, direction, or development on this project.. In the meantime I will be attempting to muddle through myself.

According to my understanding of the USPS Address Standardization/Verification api (Available under the link titled: Have an ecommerce website? - Address below) You capture the address and send it to them, via the following XML code:

http://production.shippingapis.com/ShippingAPITest.dll?API=Verify&XML=<AddressValidateRequest%20USERID="xxxxxxxxxxxx">
     <Address>
          <Address1></Address1>
          <Address2>6406 Ivy Lane</Address2>
          <City>Greenbelt</City>
          <State>MD</State> 
          <Zip5></Zip5>
          <Zip4></Zip4>
     </Address>
</AddressValidateRequest>

they verify it and then return it with the following code:

<?xml version="1.0"?> 
<AddressValidateResponse> 
     <Address ID="0"> 
          <Address2>6406 IVY LN</Address2> 
          <City>GREENBELT</City> 
          <State>MD</State> 
          <Zip5>20770</Zip5> 
          <Zip4>1440</Zip4> 
     </Address> 
</AddressValidateResponse>

HTH either the development of this addon or someone else implement this extremely useful tool.
https://www.usps.com/business/web-tools-apis/list-of-apis.htm

rszrama’s picture

Project: Commerce Core » Commerce USPS
Version: 7.x-1.8 » 7.x-2.x-dev
Component: Customer » Code

I assume you meant to post to the USPS queue?

MBfromOK’s picture

There is a USPS Queue?

I posted it here because the topic was address validation and my comment added to this discussion and addressed several peoples claim that it is hard / impossible to get access to the USPS Validation servers.

I am happy to post it there if need be, but my search of the site revealed no topic / queue for USPS.

Micah

rszrama’s picture

(If you check out the headers for my comment I've already moved it to the USPS queue.)

mrpeanut’s picture

Issue summary: View changes
Status: Active » Closed (won't fix)

I was looking for this same thing and stumbled upon this issue. To me, address verification/validation is best done in a separate module. I ended up using Commerce UPS Address Validation which does work with Commerce USPS.