aboutsummaryrefslogtreecommitdiff
path: root/underlays/osm
diff options
context:
space:
mode:
authorGeneviève Bastien <gbastien@versatic.net>2012-08-06 23:00:31 -0400
committerAntoine Beaupré <anarcat@koumbit.org>2012-08-25 08:20:30 -0400
commit8fb42f42f495095ca32a569401df21f089f0e40c (patch)
treed6ce8f56ffe12e651052f25d480c517c241b688e /underlays/osm
parentb46e0579328bcc228936397d52dcc88710f95125 (diff)
downloadikiwiki-8fb42f42f495095ca32a569401df21f089f0e40c.tar
ikiwiki-8fb42f42f495095ca32a569401df21f089f0e40c.tar.gz
OSM plugin: new config option to specify the url to fetch maps from
Diffstat (limited to 'underlays/osm')
-rw-r--r--underlays/osm/ikiwiki/osm.js7
1 files changed, 6 insertions, 1 deletions
diff --git a/underlays/osm/ikiwiki/osm.js b/underlays/osm/ikiwiki/osm.js
index d7e3d53f4..644d4b573 100644
--- a/underlays/osm/ikiwiki/osm.js
+++ b/underlays/osm/ikiwiki/osm.js
@@ -37,8 +37,13 @@ function mapsetup(divname, options) {
numZoomLevels: 18
});
+ if (options.mapurl) {
+ var newLayer = new OpenLayers.Layer.OSM("Local Tiles", options.mapurl, {numZoomLevels: 19, isBaseLayer: true});
+ map.addLayer(newLayer);
+ } else {
+ map.addLayer(new OpenLayers.Layer.OSM());
+ }
- map.addLayer(new OpenLayers.Layer.OSM());
if (options.format == 'CSV') {
pois = new OpenLayers.Layer.Text( "CSV",
{ location: options.csvurl,