I think this is very difficult...
I want to give the user the possibility to insert a city of world and see last earthquakes around it.
The problem is how create an input list with all cities.
In my form the user must before insert the country:
http://jsfiddle.net/Dimcho/LUZvS/
<div class=datalist-holder>
<input list=country name=country class=datalist-input />
<datalist id=country>
<option value=Afghanistan />
<option value=Albania />
<option value=Algeria />
<option value=American Samoa />
<option value=Andorra />
//...
//...
</datalist>
</div>
and this jsfiddle works very well...
but to insert the city it's a big problem, how is possible ?
How can i find good database with all cities of world with its latitude, longitude and name of city (with region/province) ?
Anyway i can't insert all cities in my page so I had thought to load a single file with all cities of inserted country using javascript
.
Is a good idea?
I would like a lot of advice, the important thing are solutions that do not slow down the code and the page. The performances are very important.
Thanks a lot and sorry for my english