Questions tagged [geonames]

Geonames refers to a database / webservice to query various geographic data items such as names of places, latitude, longitude, elevation, population in various languages. It contains over 10 million geographical names categorized into nine classes and further subcategorized.

GeoNames is a worldwide geographical database. It is available for download free of charge under a creative commons attribution license. It is also available via a webservice API.

198 questions
35
votes
4 answers

Getting Time Zone from Lat Long Coordinates?

I am trying to get the time zones for latitude and longitude coordinates but am having a few problems The mistakes are probably very basic I have a table in a database with around 600 rows. Each row contains a lat long coordinate for somewhere in…
John Smith
  • 2,448
  • 7
  • 54
  • 78
16
votes
4 answers

Importing data from geonames.org database into MySQL DB

Does anyone how to import a geonames.org data into my database? The one i'm trying to import is http://download.geonames.org/export/dump/DO.zip, and my DB its a MySQL db.
Luis D Urraca
  • 2,024
  • 4
  • 24
  • 46
15
votes
2 answers

Echo status message in php geonames timezone

I'm using following code php to get timezone: $url = 'http://api.geonames.org/timezone?lat=' . $latitude . '&lng=' . $longitude . '&username=demo'; $xml = simplexml_load_file($url); foreach($xml->children() as $timezone) …
grigione
  • 697
  • 2
  • 11
  • 37
15
votes
2 answers

Google places API hierarchy - neighbourhood/suburb -> city -> region -> country

Problem - people posting in various places based on their interest while other people are searching for posts in greater areas. e.g. - user A posts under Bondi Beach, a suburb of Sydney. user B searches for posts under Sydney. Desired outcome - user…
giLisH
  • 196
  • 1
  • 12
12
votes
1 answer

Geonames vs Google Maps

I am building an application that uses both GeoNames and Google Places API. The thing is, when I do a search nearby by a specific location (say lat: 47.16, lng: 27.56) on both of the services I do not know how to remove entities that appear both in…
scarleth ohara
  • 357
  • 2
  • 12
10
votes
3 answers

C# - Get Country from latitude/longitude without API

Is it possible with a C# library or an update database about geographical coordinates coutries to get the country name from latitude and longitude Without an API like the Google Maps’ JavaScript API ?
k4st0r42
  • 1,174
  • 1
  • 15
  • 29
8
votes
1 answer

Using geonames service locally

I was planning to use geonames API but actually it seems far more sensible to use the geonames locally and not use their web API. So my question is, does anyone know how to interface with the geonames data locally? Do I need to manually import it…
Jimmy
  • 12,087
  • 28
  • 102
  • 192
6
votes
4 answers

Retrieve cities list of a country

Which is the best api to retrieve all the cities in given country? I tried downloading from geonames. but it seems data is not reliable.` Is it possible to query city, along with state and country in overpass api? Can you please suggest a better way…
Kishore K
  • 2,425
  • 4
  • 18
  • 18
6
votes
3 answers

get 2 letter state/province abbreviation

So I'm using the GeoNames API to get country and state/province information which I'm using to populate select dropdowns in a form. This form submits it's information to a SOAP web service and the SOAP Server only understands the country and…
Devin Crossman
  • 7,454
  • 11
  • 64
  • 102
5
votes
1 answer

What is the best method to make location disambiguation for geonames data?

What is the best method to do location disambiguation for geonames data? There are some scoring algorithm for geonames search, but they do not open source it and I'm not sure they are very sophisticated. (i.e. for soma, ca it returns Soma lake in…
yura
  • 14,489
  • 21
  • 77
  • 126
5
votes
1 answer

How do I have Geonames api work with https?

I'm sending ajax requests to Geonames Search api. It works pretty well on http protocol. But when I switch to https (both my own server and the api requests), my requests are blocked by the browser: Geonames https certificate seems to be…
Abrab
  • 751
  • 1
  • 8
  • 19
5
votes
3 answers

Assessing OpenStreetMap for international routing

I have been using a commercial solution for route distances and travel times for North America and Western/Mid Europe. I am considering expanding the project to cover other countries - and perhaps the entire world. A very limited budget and patchy…
winwaed
  • 7,645
  • 6
  • 36
  • 81
5
votes
0 answers

Getting the human-readable abbreviations for admin1 level records in Geonames

For the United States, the admin1 code corresponds to the state abbreviation, which makes it very convenient to do a city, state lookup. However, for countries like Canada where the admin1 code is a number (e.g. 01 for Alberta) it's no longer…
Jordan Reiter
  • 20,467
  • 11
  • 95
  • 161
4
votes
3 answers

How to get the nearby cities of a city(geonameid) in python?

Given a radius of 100 KM from the base city(geonameid) i need to find the nearby cities. My script is in python. Is there any API to find it out ? Thanks
shaikh
  • 1,355
  • 4
  • 16
  • 30
4
votes
1 answer

How to enrich places with geonames ID

I have a list of places which I would enrich with the IDs from geonames. Since geonames by default it's embedded into WikiData I chose to go directly via SPARQL using WikiData endpoint. My workflow: I have imported the excel file into OpenRefine…
Pelide
  • 468
  • 1
  • 4
  • 19
1
2 3
13 14