• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Apps Find the user's zip code

wige

Newbie
I am creating a new app that will allow users to search for local concerts. This app will pull data from a web database that uses a supplied zip code or state to determine the market area that should be searched.

What is the best way to determine a user's current zip code? I can't seem to find much documentation on getting information from the user's network location - how to do it, what format it is in, ways to convert that to a zip code - all the samples seem to use the GPS, which is overkill for this app. Any suggestions?
 
Sounds like a good idea for an app.

Even the user's network location is stored as lat/long in the phone. It just isn't as precise.
For a zipcode lookup though, it ought to be more than close enough.

I couldn't find any easy way to do a web lookup that returns a zipcode based on lat/long, but I did find a free database in .csv format that gives this information.

It's a few years old, but may serve as a start.

Free Zip Code Latitude and Longitude Database
 
Back
Top Bottom