12

Kind of a programming question...

You create a sign up form and their address is taken from a list of countries and cities. Is there somewhere on the interwebs I can grab these lists from to stick in my listboxes?

NibblyPig
  • 51,118
  • 72
  • 200
  • 356
  • Sigh, this is going to end up on meta, I know. I'm closing lots of similars as dupes of this one. All these questions are full of rotting links and spam, so don't take it personal. Just trying to clean up. –  Mar 06 '12 at 15:07
  • Possibly, although the reply states there is an ISO list which seems like a reasonable, unlocalized, unchanging answer. – NibblyPig Mar 06 '12 at 16:02
  • The ISO list is the way to go, definitely, and will *probably* not rot. –  Mar 06 '12 at 16:03

4 Answers4

7

Try this list. Link was updated to the new location.

https://www.iso.org/obp/ui/#iso:pub:PUB500001:en

Scoregraphic
  • 7,110
  • 4
  • 42
  • 64
1

if u use asp

http://www.codeproject.com/aspnet/CountryCombo.asp

This one only has countries

Haim Evgi
  • 123,187
  • 45
  • 217
  • 223
0

Country list can be grabbed from:

http://en.wikipedia.org/wiki/List_of_sovereign_states

But list of all cities of all countries, I think even if you can get that, it would be a bad options. Just let the user enter the city. Though you can have states of some big countries where your visitors are mainly from.

Priyank Bolia
  • 14,077
  • 14
  • 61
  • 82
0

You could take a look at either of these two for geographic data webservices. I would suggest letting the user input their location and then looking it up via these services, or you can download the data from geonames

(The GeoNames geographical database covers all countries and contains over eight million placenames that are available for download free of charge.)

http://www.geonames.org

http://developer.yahoo.com/geo/geoplanet/

Nick Allen
  • 11,970
  • 11
  • 45
  • 58