I'm using Maxmind's free DAT file to calculate latitude and longitudes from IP addresses - that much works fine and was very straightforward to implement.
However, I've run into an issue where I would like the user to enter 开发者_C百科their zipcode and automatically calculate the latitude and longitude for that zipcode.
Does anyone have any experience doing this with Maxmind's database? If so, how did you achieve it.
Thanks in advance
JP
I use MaxMind's GeoLite City database, in CSV format. The DAT format is great for IP geolocation, but the CSV can be imported into any relational database for quick zip code lookups. It contains most of the US zip codes, Canada and many other countries' postal codes mapped to their corresponding city and latitude/longitude.
If you need additional precision, buy their commercial database.
If you are doing this only in the US, you can build this information from Census or Postal data. I do not have experience with MaxMind.
精彩评论