ITsolutionWizard
asked on
zip code to city list
I have simple html form allow to enter zip code. my goal is if the user put 5 digital there, and it will populate
list of city in <div id=cityList></div>, and when <div> has value</div> then I can click on city, and populate the selected city
into another textbox <input type="text" id=city>
How can I do that in javascript?
list of city in <div id=cityList></div>, and when <div> has value</div> then I can click on city, and populate the selected city
into another textbox <input type="text" id=city>
How can I do that in javascript?
Understand that the USPS API is only to be used as part of a solution that uses the USPS Shipping service. It is not intended to be used in the manner you are suggesting.
That said, if the author is intending to use the API is such a way, I have worked with this in the past to create a PHP solution that uses their API to verify addresses entered on our ordering site. It is fairly easy to use.
That said, if the author is intending to use the API is such a way, I have worked with this in the past to create a PHP solution that uses their API to verify addresses entered on our ordering site. It is fairly easy to use.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ZIP Code API offers this very service. You can create a free account that allows up to 50 requests per hour, or sign up for an actual usage plan.
ZIP Code API Examples
ZIP Code API Examples
Personally, I would rather use the one from the USPS because I don't have to keep the data updated and some 3rd party DB's are outdated now.