www.webdeveloper.com
Results 1 to 7 of 7

Thread: country database

  1. #1
    Join Date
    Nov 2007
    Posts
    4

    country database

    Hi,

    I'm a Web developer and I'm working on the user registration now. I need to put into database all the countries, currencies, country prefixes and the continent for each of the countries. It takes some effort to do this, so I've been searching the Web for a script, which would add all of these into database, but I failed.

    Please, does anyone know about anything, which can do this?

  2. #2
    Join Date
    Jun 2008
    Posts
    62
    The list isn't complete, but the best I could find. You may convert from CSV to SQL for yourself, however.
    Code:
    Country	,	Abbrev.	,	Basic Unit	,	Subunit
    Afghanistan	,	AF	,	afghani	,	100 puls
    Albania	,	AL	,	lek	,	100 qindarka
    Algeria	,	DZ	,	dinar	,	100 centimes
    Andorra	,	AD	,	peseta	,	100 centimos
    Angola	,	AO	,	kwanza	,	100 lwei
    Antigua and Barbuda	,	AG	,	dollar	,	100 cents
    Argentina	,	AR	,	peso	,	100 centavos
    Armenia	,	AM	,	dram	,	100 lumma
    Australia	,	AU	,	dollar	,	100 cents
    Austria	,	AT	,	schilling	,	100 groschen 
    Azerbaijan	,	AZ	,	manat	,	100 qepiq
    Bahamas	,	BS	,	dollar	,	100 cents
    Bahrain	,	BH	,	dinar	,	1000 fils
    Bangladesh	,	BD	,	taka	,	100 poisha
    Barbados	,	BB	,	dollar	,	100 cents
    Belarus	,	BY	,	rubel	,	100 kapeikas
    Belgium	,	BE	,	franc	,	100 centimes
    Belize	,	BZ	,	dollar	,	100 cents
    Benin	,	BJ	,	franc	,	100 centimes
    Bhutan	,	BT	,	ngultrum	,	100 chetrum
    Bolivia	,	BO	,	boliviano	,	100 centavos
    Bosnia and Herzegovina	,	BA	,	marka	,	100 pfenigs
    Botswana	,	BW	,	pula	,	100 thebe
    Brazil	,	BR	,	real	,	100 centavos
    Brunei	,	BN	,	dollar	,	100 cents
    Bulgaria	,	BG	,	lev	,	100 stotinki
    Burkina Faso	,	BF	,	franc	,	100 centimes
    Burundi	,	BI	,	franc	,	100 centimes
    Cambodia	,	KH	,	riel	,	100 sen
    Cameroon	,	CM	,	franc	,	100 centimes
    Canada	,	CA	,	dollar	,	100 cents
    Cape Verde	,	CV	,	escudo	,	100 centavos
    Central African Republic	,	CF	,	franc	,	100 centimes
    Chad	,	TD	,	franc	,	100 centimes
    Chile	,	CL	,	peso	,	100 centavos
    China	,	CN	,	yuan	,	10 jiao
    Colombia	,	CO	,	peso	,	100 centavos
    Comoros	,	KM	,	franc	,	100 centimes
    Congo (Dem. Rep. of)	,	CD	,	franc	,	100 centimes
    Congo (Rep. of)	,	CG	,	franc	,	100 centimes
    Costa Rica	,	CR	,	colon	,	100 centimos 
    Croatia	,	HR	,	kuna	,	100 lipa 
    Cuba	,	CU	,	peso	,	100 centavos 
    Cyprus	,	CY	,	pound	,	100 cents 
    Czech Republic	,	CZ	,	koruna	,	100 halers 
    Denmark	,	DK	,	krone	,	100 øre 
    Djibouti	,	DJ	,	franc	,	100 centimes 
    Dominica	,	DM	,	dollar	,	100 cents
    Dominican Republic	,	DO	,	peso	,	100 centavos
    Ecuador	,	EC	,	sucre	,	100 centavos
    Egypt	,	EG	,	pound	,	100 piasters
    El Salvador	,	SV	,	colon	,	100 centavos
    Equatorial Guinea	,	GQ	,	franc	,	100 centimes
    Eritrea	,	ER	,	nakfa	,	100 cents 
    Estonia	,	EE	,	kroon	,	100 senti
    Ethiopia	,	ET	,	birr	,	100 cents
    Fiji	,	FJ	,	dollar	,	100 cents
    Finland	,	FI	,	markka	,	100 pennis
    France	,	FR	,	franc	,	100 centimes
    Gabon	,	GA	,	franc	,	100 centimes
    Gambia	,	GM	,	dalasi	,	100 bututs
    Georgia	,	GE	,	lari	,	100 tetri
    Germany	,	DE	,	deutsche mark	,	100 pfennigs
    Ghana	,	GH	,	cedi	,	100 pesewas
    Greece	,	GR	,	drachma	,	100 lepta
    Grenada	,	GD	,	dollar	,	100 cents
    Guatemala	,	GT	,	quetzal	,	100 centavos
    Guinea	,	GN	,	franc	,	100 centimes
    Guinea-Bissau	,	GW	,	franc	,	100 centimes
    Guyana	,	GY	,	dollar	,	100 cents
    Haiti	,	HT	,	gourde	,	100 centimes
    Honduras	,	HN	,	lempira	,	100 centavos
    Hong Kong	,	HK	,	dollar	,	100 cents
    Hungary	,	HU	,	forint	,	100 fillers
    Iceland	,	IS	,	krona	,	100 aurar
    India	,	IN	,	rupee	,	100 paise
    Indonesia	,	ID	,	rupiah	,	100 sen
    Iran	,	IR	,	rial	,	100 dinars
    Iraq	,	IQ	,	dinar	,	1000 fils
    Ireland	,	IE	,	pound	,	100 pence
    Israel	,	IL	,	sheqel	,	100 agorot
    Italy	,	IT	,	lira	,	100 centesimi
    Ivory Coast	,	CI	,	franc	,	100 centimes
    Jamaica	,	JM	,	dollar	,	100 cents
    Japan	,	JP	,	yen	,	100 sen
    Jordan	,	JO	,	dinar	,	100 piasters
    Kazakhstan	,	KZ	,	tenge	,	100 tiyin
    Kenya	,	KE	,	shilling	,	100 cents
    Kiribati	,	KI	,	dollar	,	100 cents
    Kuwait	,	KW	,	dinar	,	1000 fils
    Kyrgyzstan	,	KG	,	som	,	100 tyiyn
    Laos	,	LA	,	kip	,	100 at
    Latvia	,	LV	,	lats	,	100 santimi
    Lebanon	,	LB	,	livre	,	100 piasters
    Lesotho	,	LS	,	loti	,	100 lisente
    Liberia	,	LR	,	dollar	,	100 cents
    Libya	,	LY	,	dinar	,	100 dirhams
    Liechtenstein	,	LI	,	franc	,	100 centimes
    Lithuania	,	LT	,	litas	,	100 centas
    Luxembourg	,	LU	,	franc	,	100 centimes
    Macao	,	MO	,	pataca	,	100 avos 
    Macedonia	,	MK	,	denar	,	100 deni
    Madagascar	,	MG	,	franc	,	100 centimes
    Malawi	,	MW	,	kwacha	,	100 tambala
    Malaysia	,	MY	,	ringgit	,	100 sen
    Maldives	,	MV	,	rufiyaa	,	100 laari
    Mali	,	ML	,	franc	,	100 centimes
    Malta	,	MT	,	lira	,	100 cents
    Marshall Islands	,	MH	,	dollar	,	100 cents
    Mauritania	,	MR	,	ouguiya	,	5 khoums
    Mauritius	,	MU	,	rupee	,	100 cents
    Mexico	,	MX	,	peso	,	100 centavos
    Micronesia	,	FM	,	dollar	,	100 cents
    Moldova	,	MD	,	leu	,	100 bani
    Monaco	,	MC	,	franc	,	100 centimes
    Mongolia	,	MN	,	tugrik	,	100 mongo
    Morocco	,	MA	,	dirham	,	100 centimes
    Mozambique	,	MZ	,	metical	,	100 centavos
    Myanmar	,	MM	,	kyat	,	100 pyas
    Namibia	,	NA	,	dollar	,	100 cents
    Nauru	,	NR	,	dollar	,	100 cents
    Nepal	,	NP	,	rupee	,	100 paisa
    Netherlands	,	NL	,	guilder	,	100 cents
    New Zealand	,	NZ	,	dollar	,	100 cents
    Nicaragua	,	NI	,	cordoba	,	100 centavos
    Niger	,	NE	,	franc	,	100 centimes
    Nigeria	,	NG	,	naira	,	100 kobo
    North Korea	,	KP	,	won	,	100 chon
    Norway	,	NO	,	krone	,	100 øre 
    Oman	,	OM	,	rial	,	1000 baisa
    Pakistan	,	PK	,	rupee	,	100 paisa
    Palau	,	PW	,	dollar	,	100 cents
    Panama	,	PA	,	balboa	,	100 centesimos
    Papua New Guinea	,	PG	,	kina	,	100 toea
    Paraguay	,	PY	,	guarani	,	100 centimos
    Peru	,	PE	,	sol	,	100 centimos
    Philippines	,	PH	,	peso	,	100 centavos
    Poland	,	PL	,	zloty	,	100 groszy
    Portugal	,	PT	,	escudo	,	100 centavos
    Qatar	,	QA	,	riyal	,	100 dirhams
    Romania	,	RO	,	leu	,	100 bani
    Russia	,	RU	,	ruble	,	100 kopeks
    Rwanda	,	RW	,	franc	,	100 centimes
    Saint Kitts and Nevis	,	KN	,	dollar	,	100 cents
    Saint Lucia	,	LC	,	dollar	,	100 cents
    Saint Vincent and the Grenadines	,	VC	,	dollar	,	100 cents
    Samoa	,	WS	,	tala	,	100 sene
    San Marino	,	SM	,	lira	,	100 centesimi
    São Tomé and Príncipe	,	ST	,	dobra	,	100 centimos
    Saudi Arabia	,	SA	,	riyal	,	100 halalas
    Senegal	,	SN	,	franc	,	100 centimes
    Seychelles	,	SC	,	rupee	,	100 cents
    Sierra Leone	,	SL	,	leone	,	100 cents
    Singapore	,	SG	,	dollar	,	100 cents 
    Slovakia	,	SK	,	koruna	,	100 haliers
    Slovenia	,	SI	,	tolar	,	100 stotins
    Solomon Islands	,	SB	,	dollar	,	100 cents
    Somalia	,	SO	,	shilling	,	100 cents
    South Africa	,	ZA	,	rand	,	100 cents
    South Korea	,	KR	,	won	,	100 chon
    Spain	,	ES	,	peseta	,	100 centimos
    Sri Lanka	,	LK	,	rupee	,	100 cents
    Sudan	,	SD	,	dinar	,	10 pounds
    Suriname	,	SR	,	guilder	,	100 cents
    Swaziland	,	SZ	,	lilangeni	,	100 cents
    Sweden	,	SE	,	krona	,	100 öre
    Switzerland	,	CH	,	franc	,	100 centimes
    Syria	,	SY	,	pound	,	100 piasters
    Taiwan	,	TW	,	dollar	,	100 cents
    Tajikistan	,	TJ	,	ruble	,	100 tanga
    Tanzania	,	TZ	,	shilling	,	100 cents
    Thailand	,	TH	,	baht	,	100 satang
    Togo	,	TG	,	franc	,	100 centimes
    Tonga	,	TO	,	pa’anga	,	100 seniti
    Trinidad and Tobago	,	TT	,	dollar	,	100 cents
    Tunisia	,	TN	,	dinar	,	1000 millimes
    Turkey	,	TR	,	lira	,	100 kurus
    Turkmenistan	,	TM	,	manat	,	100 tenge
    Tuvalu	,	TV	,	dollar	,	100 cents
    Uganda	,	UG	,	shilling	,	100 cents
    Ukraine	,	UA	,	hryvnia	,	100 kopiykas
    United Arab Emirates	,	AE	,	dirham	,	100 fils
    United Kingdom	,	GB	,	pound	,	100 pence
    United States	,	US	,	dollar	,	100 cents
    Uruguay	,	UY	,	peso	,	100 centesimos
    Uzbekistan	,	UZ	,	sum	,	100 tyyn
    Vanuatu	,	VU	,	vatu	,	 
    Vatican City	,	VA	,	lira	,	100 centesimi
    Venezuela	,	VE	,	bolivar	,	100 centimos
    Vietnam	,	VN	,	dong	,	10 hao
    Yemen	,	YE	,	rial	,	100 fils
    Yugoslavia	,	YU	,	dinar	,	100 para
    Zambia	,	ZM	,	kwacha	,	100 ngwee
    Zimbabwe	,	ZW	,	dollar	,	100 cents

  3. #3
    Join Date
    Sep 2006
    Posts
    655

    Cool

    Copy/paste the following


    Code:
    <select name="frmRegisterSelectCountry">
    					<option value="" selected>- Select Country -</option>
    																				<option value="Afghanistan">Afghanistan</option> 
    										<option value="Albania">Albania</option> 
    										<option value="Algeria">Algeria</option> 
    										<option value="American Samoa">American Samoa</option> 
    										<option value="Andorra">Andorra</option> 
    										<option value="Angola">Angola</option> 
    										<option value="Anguilla">Anguilla</option> 
    										<option value="Antarctica">Antarctica</option> 
    										<option value="Argentina">Argentina</option> 
    										<option value="Armenia">Armenia</option> 
    										<option value="Aruba">Aruba</option> 
    										<option value="Australia">Australia</option> 
    										<option value="Austria">Austria</option> 
    										<option value="Azerbaijan">Azerbaijan</option> 
    										<option value="Bahamas">Bahamas</option> 
    										<option value="Bahrain">Bahrain</option> 
    										<option value="Bangladesh">Bangladesh</option> 
    										<option value="Barbados">Barbados</option> 
    										<option value="Belarus">Belarus</option> 
    										<option value="Belgium">Belgium</option> 
    										<option value="Belize">Belize</option> 
    										<option value="Benin">Benin</option> 
    										<option value="Bermuda">Bermuda</option> 
    										<option value="Bhutan">Bhutan</option> 
    										<option value="Bolivia">Bolivia</option> 
    										<option value="Bosnia">Bosnia</option> 
    										<option value="Botswana">Botswana</option> 
    										<option value="Bouvet Island">Bouvet Island</option> 
    										<option value="Brazil">Brazil</option> 
    										<option value="Bulgaria">Bulgaria</option> 
    										<option value="Burkina Faso">Burkina Faso</option> 
    										<option value="Burundi">Burundi</option> 
    										<option value="Cambodia">Cambodia</option> 
    										<option value="Cameroon">Cameroon</option> 
    										<option value="Canada">Canada</option> 
    										<option value="Cape Verde">Cape Verde</option> 
    										<option value="Cayman Islands">Cayman Islands</option> 
    										<option value="Chad">Chad</option> 
    										<option value="Chile">Chile</option> 
    										<option value="China">China</option> 
    										<option value="Christmas Island">Christmas Island</option> 
    										<option value="Colombia">Colombia</option> 
    										<option value="Comoros">Comoros</option> 
    										<option value="Congo">Congo</option> 
    										<option value="Cook Islands">Cook Islands</option> 
    										<option value="Costa Rica">Costa Rica</option> 
    										<option value="Croatia">Croatia</option> 
    										<option value="Cuba">Cuba</option> 
    										<option value="Cyprus">Cyprus</option> 
    										<option value="Czech Republic">Czech Republic</option> 
    										<option value="Denmark">Denmark</option> 
    										<option value="Djibouti">Djibouti</option> 
    										<option value="Dominica">Dominica</option> 
    										<option value="Dominican Republic">Dominican Republic</option> 
    										<option value="Ecuador">Ecuador</option> 
    										<option value="Egypt">Egypt</option> 
    										<option value="El Salvador">El Salvador</option> 
    										<option value="Equatorial Guinea">Equatorial Guinea</option> 
    										<option value="Eritrea">Eritrea</option> 
    										<option value="Estonia">Estonia</option> 
    										<option value="Ethiopia">Ethiopia</option> 
    										<option value="Faroe Islands">Faroe Islands</option> 
    										<option value="Fiji">Fiji</option> 
    										<option value="Finland">Finland</option> 
    										<option value="France">France</option> 
    										<option value="Gabon">Gabon</option> 
    										<option value="Gambia">Gambia</option> 
    										<option value="Georgia">Georgia</option> 
    										<option value="Germany">Germany</option> 
    										<option value="Ghana">Ghana</option> 
    										<option value="Gibraltar">Gibraltar</option> 
    										<option value="Greece">Greece</option> 
    										<option value="Greenland">Greenland</option> 
    										<option value="Grenada">Grenada</option> 
    										<option value="Guadeloupe">Guadeloupe</option> 
    										<option value="Guam">Guam</option> 
    										<option value="Guatemala">Guatemala</option> 
    										<option value="Guinea">Guinea</option> 
    										<option value="Guinea-bissau">Guinea-bissau</option> 
    										<option value="Guyana">Guyana</option> 
    										<option value="Haiti">Haiti</option> 
    										<option value="Vatican City">Vatican City</option> 
    										<option value="Honduras">Honduras</option> 
    										<option value="Hong Kong">Hong Kong</option> 
    										<option value="Hungary">Hungary</option> 
    										<option value="Iceland">Iceland</option> 
    										<option value="Indonesia">Indonesia</option> 
    										<option value="Iran">Iran</option> 
    										<option value="Iraq">Iraq</option> 
    										<option value="Ireland">Ireland</option> 
    										<option value="Israel">Israel</option> 
    										<option value="Italy">Italy</option> 
    										<option value="Jamaica">Jamaica</option> 
    										<option value="Japan">Japan</option> 
    										<option value="Jordan">Jordan</option> 
    										<option value="Kazakhstan">Kazakhstan</option> 
    										<option value="Kenya">Kenya</option> 
    										<option value="Kiribati">Kiribati</option> 
    										<option value="North Korea">North Korea</option> 
    										<option value="South Korea">South Korea</option> 
    										<option value="Kuwait">Kuwait</option> 
    										<option value="Kyrgyzstan">Kyrgyzstan</option> 
    										<option value="Lao">Lao</option> 
    										<option value="Latvia">Latvia</option> 
    										<option value="Lebanon">Lebanon</option> 
    										<option value="Lesotho">Lesotho</option> 
    										<option value="Liberia">Liberia</option> 
    										<option value="Liechtenstein">Liechtenstein</option> 
    										<option value="Lithuania">Lithuania</option> 
    										<option value="Luxembourg">Luxembourg</option> 
    										<option value="Macao">Macao</option> 
    										<option value="Macedonia">Macedonia</option> 
    										<option value="Madagascar">Madagascar</option> 
    										<option value="Malawi">Malawi</option> 
    										<option value="Malaysia">Malaysia</option> 
    										<option value="Maldives">Maldives</option> 
    										<option value="Mali">Mali</option> 
    										<option value="Malta">Malta</option> 
    										<option value="Marshall Islands">Marshall Islands</option> 
    										<option value="Martinique">Martinique</option> 
    										<option value="Mauritania">Mauritania</option> 
    										<option value="Mauritius">Mauritius</option> 
    										<option value="Mayotte">Mayotte</option> 
    										<option value="Mexico">Mexico</option> 
    										<option value="Micronesia, Federated States of">Micronesia</option> 
    										<option value="Moldova">Moldova</option> 
    										<option value="Monaco">Monaco</option> 
    										<option value="Mongolia">Mongolia</option> 
    										<option value="Montserrat">Montserrat</option> 
    										<option value="Morocco">Morocco</option>

    to be continued..

  4. #4
    Join Date
    Sep 2006
    Posts
    655
    continuing....


    Code:
    <option value="Mozambique">Mozambique</option> 
    										<option value="Myanmar">Myanmar</option> 
    										<option value="Namibia">Namibia</option> 
    										<option value="Nauru">Nauru</option> 
    										<option value="Nepal">Nepal</option> 
    										<option value="Netherlands">Netherlands</option> 
    										<option value="New Caledonia">New Caledonia</option> 
    										<option value="New Zealand">New Zealand</option> 
    										<option value="Nicaragua">Nicaragua</option> 
    										<option value="Niger">Niger</option> 
    										<option value="Nigeria">Nigeria</option> 
    										<option value="Niue">Niue</option> 
    										<option value="Norfolk Island">Norfolk Island</option> 
    										<option value="Norway">Norway</option> 
    										<option value="Oman">Oman</option> 
    										<option value="Pakistan">Pakistan</option> 
    										<option value="Palau">Palau</option> 
    										<option value="Palestinian">Palestinian</option> 
    										<option value="Panama">Panama</option> 
    										<option value="Papua New Guinea">Papua New Guinea</option> 
    										<option value="Paraguay">Paraguay</option> 
    										<option value="Peru">Peru</option> 
    										<option value="Philippines">Philippines</option> 
    										<option value="Pitcairn">Pitcairn</option> 
    										<option value="Poland">Poland</option> 
    										<option value="Portugal">Portugal</option> 
    										<option value="Puerto Rico">Puerto Rico</option> 
    										<option value="Qatar">Qatar</option> 
    										<option value="Reunion">Reunion</option> 
    										<option value="Romania">Romania</option> 
    										<option value="Russia">Russia</option> 
    										<option value="Rwanda">Rwanda</option> 
    										<option value="Saint Helena">Saint Helena</option> 
    										<option value="Saint Lucia">Saint Lucia</option> 
    										<option value="Samoa">Samoa</option> 
    										<option value="San Marino">San Marino</option> 
    										<option value="Saudi Arabia">Saudi Arabia</option> 
    										<option value="Senegal">Senegal</option> 
    										<option value="Serbia">Serbia</option> 
    										<option value="Seychelles">Seychelles</option> 
    										<option value="Sierra Leone">Sierra Leone</option> 
    										<option value="Singapore">Singapore</option> 
    										<option value="Slovakia">Slovakia</option> 
    										<option value="Slovenia">Slovenia</option> 
    										<option value="Solomon Islands">Solomon Islands</option> 
    										<option value="Somalia">Somalia</option> 
    										<option value="South Africa">South Africa</option> 
    										<option value="Spain">Spain</option> 
    										<option value="Sri Lanka">Sri Lanka</option> 
    										<option value="Sudan">Sudan</option> 
    										<option value="Suriname">Suriname</option> 
    										<option value="Swaziland">Swaziland</option> 
    										<option value="Sweden">Sweden</option> 
    										<option value="Switzerland">Switzerland</option> 
    										<option value="Syria">Syria</option> 
    										<option value="Taiwan">Taiwan</option> 
    										<option value="Tajikistan">Tajikistan</option> 
    										<option value="Tanzania">Tanzania</option> 
    										<option value="Thailand">Thailand</option> 
    										<option value="Timor-leste">Timor-leste</option> 
    										<option value="Togo">Togo</option> 
    										<option value="Tokelau">Tokelau</option> 
    										<option value="Tonga">Tonga</option> 
    										<option value="Tunisia">Tunisia</option> 
    										<option value="Turkey">Turkey</option> 
    										<option value="Turkmenistan">Turkmenistan</option> 
    										<option value="Tuvalu">Tuvalu</option> 
    										<option value="Uganda">Uganda</option> 
    										<option value="Ukraine">Ukraine</option> 
    										<option value="UAE">UAE</option> 
    										<option value="United Kingdom">United Kingdom</option> 
    										<option value="United States">United States</option> 
    										<option value="Uruguay">Uruguay</option> 
    										<option value="Uzbekistan">Uzbekistan</option> 
    										<option value="Vanuatu">Vanuatu</option> 
    										<option value="Venezuela">Venezuela</option> 
    										<option value="Viet Nam">Viet Nam</option> 
    										<option value="Yemen">Yemen</option> 
    										<option value="Zambia">Zambia</option> 
    										<option value="Zimbabwe">Zimbabwe</option>					
    					</select>

  5. #5
    Join Date
    Nov 2007
    Posts
    4
    Thanks, but it's out of date (e.g. I see there the old European currencies as Franc or Krone, now should be Euro). Don't you have an up-to-date version?

  6. #6
    Join Date
    Sep 2006
    Posts
    655
    Well, if you want updated version then you should go to sites like hotmail/excite and take a look into their sign-up form. They usually have up to date country list.

  7. #7
    Join Date
    Jul 2004
    Posts
    300
    Your best bet would be to pull something from a standard organization, such as ISO. Sure it won't be fast and probably not as easy as you want, but it would only have to be done once.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles