Welcome to WebmasterWorld Guest from 54.226.62.251

Forum Moderators: phranque

Message Too Old, No Replies

Contact forms - automatic address from postcode (zip code) entry

automatic address from postcode

     

brd1984

9:56 am on Jan 16, 2009 (gmt 0)

5+ Year Member



Does anyone know of any available scripts for contact forms which look up a user's address when they input their postcode (zip code)?

I've seen it being used on quite a few sites but i've had no joy in finding out how they do it.

Thanks
Ben

danielcer

10:13 am on Jan 16, 2009 (gmt 0)

5+ Year Member



Some places provide APIs that map zip codes to cities and states But, you have to pay for the service.

If you look hard enough, you can probably just find a list you can download somewhere.

[edited by: engine at 10:48 am (utc) on Jan. 16, 2009]
[edit reason] See TOS [/edit]

rocknbil

1:52 pm on Jan 16, 2009 (gmt 0)

WebmasterWorld Senior Member rocknbil is a WebmasterWorld Top Contributor of All Time 10+ Year Member



.... which look up a user's address when they input their postcode (zip code)?

I can't imagine how you'd look up the address from the zip code as there could be millions of addresses within a zip code, but you should be able to write a script that can extrapolate the zip code from the address using the USPS Zip Code Lookup API [usps.com].

There are code samples in the docs to get you started in multiple programming languages.

piatkow

4:04 pm on Jan 16, 2009 (gmt 0)

WebmasterWorld Senior Member piatkow is a WebmasterWorld Top Contributor of All Time 5+ Year Member Top Contributors Of The Month



UK postcodes apply to a small set of properties and can be used to offer a pick list of addresses. Typically it would be the number of addresses whose letters the postman could carry in his hand at one time.

You would have to pay for access to the file.

If you are dealing with multiple countries you would need to deal separately with each post office or find a third party processor who has done this for you.

 

Featured Threads

Hot Threads This Week

Hot Threads This Month