I have created an OpenStreetMap server using this guide: switch to osm it's very good and works like a charm. I have also been able to add a new theme using TileMill and osm-brigth
However, I now want to be able to switch between two themes, osm-bright and osm-night. Is this an apache question or is there a way to modify mapnik to be able to get a parameter from for example openlayers to switch between these two themes?
Gratefull for any advice.
carto -l project.mml > osm-night.xml
, like you probably did with osm-bright./etc/renderd.conf
adding a second style section, like for osm-bright, but with names and paths to osm-night.After that you will have two set of tiles generated: e.g. /osm-bright/{z}/{x}/{y}.png
and /osm-night/{z}/{x}/{y}.png
. Add both of them as tile layers to your OpenLayers page, and add a layer switcher. (I use Leaflet and not sure how it's done in OL).