SP3 Freiburg – Oberkirch – Karlsruhe

 

Route

+−Leaflet, © OpenStreetMap contributors window.WPLeafletMapPlugin = window.WPLeafletMapPlugin || []; window.WPLeafletMapPlugin.push(function () { var baseUrl = 'https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', base = (!baseUrl && window.MQ) ? MQ.mapLayer() : L.tileLayer(baseUrl, { subdomains: 'abc' }), options = L.Util.extend({}, { maxZoom: 20, minZoom: 0, layers: [base], zoomControl: 1, scrollWheelZoom: 0, doubleClickZoom: 0, attributionControl: false }, {}), map = L.map('leaflet-map-1', options) .setView([44.67,-63.61],12); if (1) { map._shouldFitBounds = true; } var attControl = L.control.attribution({prefix:false}).addTo(map); attControl.addAttribution('Leaflet'); attControl.addAttribution('\r\n© OpenStreetMap contributors'); window.WPLeafletMapPlugin.maps.push(map); }); // end add window.WPLeafletMapPlugin = window.WPLeafletMapPlugin || []; window.WPLeafletMapPlugin.push(function () { var src = 'https://pilgerwege-schoenstatt.de/wp-content/uploads/2019/07/SP3-Freiburg-Karlsruhe.gpx ',                     default_style = {"color":"red"}, rewrite_keys = { stroke : 'color', 'stroke-width' : 'weight', 'stroke-opacity' : 'opacity', fill : 'fillColor', 'fill-opacity' : 'fillOpacity', }, layer = L.ajaxGeoJson(src, { type: 'gpx', style : layerStyle, onEachFeature : onEachFeature, }), fitbounds = 0, popup_text = window.WPLeafletMapPlugin.unescape(''), popup_property = '', group = window.WPLeafletMapPlugin.getCurrentGroup(); layer.addTo( group ); window.WPLeafletMapPlugin.geojsons.push( layer ); if (fitbounds) { layer.on('ready', function () { this.map.fitBounds( this.getBounds() ); }); } function layerStyle (feature) { var props = feature.properties || {}; var style = {}; var camelFun = function camelFun (_, first_letter) { return first_letter.toUpperCase(); }; for (var key in props) { if (key.match('-')) { var camelcase = key.replace(/-(\w)/, camelFun); style[ camelcase ] = props[ key ]; } // rewrite style keys from geojson.io if (rewrite_keys[ key ]) { style[ rewrite_keys[ key ] ] = props[ key ]; } } style = L.Util.extend(style, default_style); return style; } function onEachFeature (feature, layer) { var props = feature.properties || {}; var text = popup_property ? props[ popup_property ] : window.WPLeafletMapPlugin.template( popup_text, feature.properties ); if (text) { layer.bindPopup( text ); } } });