I've edited the local.php settings file in Nominatim/settings and add the following line: @define('CONST_Website_BaseURL', 'http://localhost/nominatim/'); Now the map is rendered on my page. However, it's loading tiles from OSM server. I tried to change http://b.tile.openstreetmap.org/${z}/${x}/${y}.png by http://localhost/nominatim/${z}/${x}/${y}.png in tiles.js but it's not working. Indeed, I checked in the localhost/nominatim folder and there's no tiles in it... In other words, where can I find them? |
Nominatim provides search functionality only, it does not provide a rendered map. For details on setting up tile rendering you may want to have a look at these help topics (there are probably others if you search) https://help.openstreetmap.org/questions/136/how-do-i-render-my-own-maps-for-my-website https://help.openstreetmap.org/questions/8371/how-to-serve-tiles-from-my-own-server There is also a virtual machine image setup to do both nominatim and tiles - although it currently has problems with more recent osm data in nominatim: http://wiki.openstreetmap.org/wiki/Virtual_machine_image By default Nominatim is setup to use OSM tiles, but there are other providers of pre-rendered tiles available, for instance MapQuest. Alternatively you can render your own and provide a custom url - but this requires additional software and another copy of the OSM database. answered 13 Jun '13, 16:35 twain 2
Thank you very much for this really comprehensive answer. It's very helpful. I'm thinking using Gisgraphy (http://stevenyue.com/2013/04/24/install-gisgraphy-on-ubuntu-12-04-from-scratch/) instead of Nominatim (which is really hard to set up...) for search functionality . Lucas
(13 Jun '13, 17:00)
Kalu06
1
Gisgraphy is easier and quicker to setup but less complete. It depends on your usage as to which one is more suitable. You Probably want to compare the results from their demo system http://services.gisgraphy.com/public/geocoding.html and http://nominatim.openstreetmap.org/ and see which best meets your needs.
(13 Jun '13, 17:29)
twain
1
Indeed Nominatim seems to be much more complete and more appropriate to my needs. Thanks for your advices twain.
(14 Jun '13, 09:31)
Kalu06
@Kalu06 The link should be http://stevenyue.com/2013/04/24/install-gisgraphy-on-ubuntu-12-04-from-scratch/ You happened to include an extra ')' in the link' href, which will lead to a 404 page, and the google webmaster tool keeps telling me the error, so I have to comment it here to clear it. Sorry for any inconvenience :)
(18 Jul '14, 15:36)
steven_yue
@steven_yue I'm not Kalu06 but have fixed it :)
(18 Jul '14, 15:40)
SomeoneElse ♦
|
The details I suspect are here:
https://help.openstreetmap.org/questions/23250/osm2pgsql-import-for-geo-coding