What is the best way to handle signups for new users when you want them to register anonymously but identify their country, city and Zip/Postal code? Some countries don't have postal codes. I would like to be able to show user location on on Google Maps. Are then any API's to handle this process in a clean way?
I can suggest MaxMind and if you use nginx web server NginxHttpGeoIPModule that can be used with MaxMind.
The answer to that comes in 3-parts:
If you're just starting out, I would suggest just asking the user with an unobtrusive form. It is the simplest solution, it works, and it does not have any dependencies on browsers or 3rd party services.
You can grab user's IP address during sign up, find out his location based on that IP address and then use the location info for google map. Here are couple of solutions that you can use to find out location based on IP