MARCHER – PRIER
var osmLink = 'OpenStreetMap France', thunLink = 'OpenStreetMap HOT', esriLink = 'Esri WorldStreetMap', EsriWorldImagery = 'Satellite', CyclOSM = 'CyclOSM';
var esriUrl = 'https://{s}.tile.openstreetmap.fr/osmfr/{z}/{x}/{y}.png', esriAttrib = '', osmUrl = 'https://{s}.tile.openstreetmap.fr/osmfr/{z}/{x}/{y}.png', osmAttrib = '© ' + osmLink + ' Contributors', landUrl = 'https://{s}.tile.openstreetmap.fr/hot/{z}/{x}/{y}.png', thunAttrib = '© '+osmLink+' Contributors & '+thunLink, EsriWorldImageryUrl = 'https://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/tile/{z}/{y}/{x}', EsriWorldImageryAttrib = '© '+osmLink+' Tiles © Esri — Source: Esri, i-cubed, USDA, USGS, AEX, GeoEye, Getmapping, Aerogrid, IGN, IGP, UPR-EGP, and the GIS User Community', CyclOSMUrl = 'https://dev.{s}.tile.openstreetmap.fr/cyclosm/{z}/{x}/{y}.png', CyclOSMAttrib = '© '+osmLink+' CyclOSM | Map data: © OpenStreetMap contributors';
var esriMap = L.tileLayer(esriUrl, {attribution: esriAttrib}), osmMap = L.tileLayer(osmUrl, {attribution: osmAttrib}), landMap = L.tileLayer(landUrl, {attribution: thunAttrib}), EsriWorldImagery = L.tileLayer(EsriWorldImageryUrl, {attribution: EsriWorldImageryAttrib}), CyclOSM = L.tileLayer(CyclOSMUrl, {attribution: CyclOSMAttrib});
var tiles = L.tileLayer('https://{s}.tile.osm.org/{z}/{x}/{y}.png', { maxZoom: 18, attribution: '© OpenStreetMap contributors', id: 'mapbox/streets-v11', tileSize: 512, zoomOffset: -1 }),
latlng = L.latLng(50.500, 4.600); var lat = 47.4; var lng = 1.6;
var zoom = 9;
var options = { maxZoom: 18, center: latlng, zoom: 9, zoomControl: false,layers: [tiles], tap:false, } var map = L.map('map', options);
var baseLayers = { 'Custom OpenStreetMap': tiles, 'OpenStreetMap France': esriMap, 'OSM Mapnik': osmMap, 'OpenStreetMap HOT': landMap, 'Satellite':EsriWorldImagery, 'Cycle OSM':CyclOSM };
/// ------ GEOCODER var IconSearch = L.icon({ iconUrl: "https://marcher-prier.be/wp-content/plugins/events-manager-openstreetmap/images/iconsearch.png", iconSize: [32, 48], iconAnchor: [16, 48], popupAnchor: [-3, -48], });
var optionsSearch = { placeholder: "Rechercher des lieux ou des adresses", //position: "topright" }
// create the geocoding control and add it to the map var searchControl = L.esri.Geocoding.geosearch(optionsSearch).addTo(map);
// create an empty layer group to store the results and add it to the map var results = L.layerGroup().addTo(map);
// listen for the results event and add every result to the map searchControl.on("results", function(data) { results.clearLayers(); for (var i = data.results.length - 1; i >= 0; i--) { results.addLayer(L.marker(data.results[i].latlng, { icon: IconSearch })); } });
// ------ END L.control.layers(baseLayers).addTo(map); var markers = L.markerClusterGroup();
for (var i = 0; i < addressPoints.length; i++) { var a = addressPoints[i]; var title = a[2]; var urlIcon = a[6] var catIcon = L.icon({ iconUrl: urlIcon, iconSize: [33, 44], iconAnchor: [16.5, 44], popupAnchor: [-3, -44], }); // create popup contents var customPopup = '' + a[4] + '
' + a[5] + '
';
// specify popup options var customOptions = {'maxWidth': '500','className' : 'customevent'}
var marker = L.marker(new L.LatLng(a[0], a[1]), { title: title, icon: catIcon }); marker.bindPopup(customPopup,customOptions); markers.addLayer(marker); } // create legend : https://tomik23.github.io/leaflet-examples/#62.count-markers
const legend = L.control({ position: 'bottomleft' });
legend.onAdd = function () { const div = L.DomUtil.create('div', 'description'); L.DomEvent.disableClickPropagation(div);
const allMarkers = L.DomUtil.create('div', 'all-markers'); allMarkers.insertAdjacentHTML( 'beforeend', '
' );
div.appendChild(allMarkers); return div; };
legend.addTo(map);
map.addLayer(markers);
// custom zoom bar control that includes a Zoom Home function L.Control.zoomHome = L.Control.extend({ options: { position: 'topleft', zoomInText: '+', zoomInTitle: 'Zoom avant', zoomOutText: '-', zoomOutTitle: 'Zoom arrière', zoomHomeText: '', zoomHomeTitle: 'Zoom accueil' },
onAdd: function (map) { var controlName = 'gin-control-zoom', container = L.DomUtil.create('div', controlName + ' leaflet-bar'), options = this.options;
this._zoomInButton = this._createButton(options.zoomInText, options.zoomInTitle, controlName + '-in', container, this._zoomIn); this._zoomHomeButton = this._createButton(options.zoomHomeText, options.zoomHomeTitle, controlName + '-home', container, this._zoomHome); this._zoomOutButton = this._createButton(options.zoomOutText, options.zoomOutTitle, controlName + '-out', container, this._zoomOut);
this._updateDisabled(); map.on('zoomend zoomlevelschange', this._updateDisabled, this);
return container; },
onRemove: function (map) { map.off('zoomend zoomlevelschange', this._updateDisabled, this); },
_zoomIn: function (e) { this._map.zoomIn(e.shiftKey ? 3 : 1); },
_zoomOut: function (e) { this._map.zoomOut(e.shiftKey ? 3 : 1); },
_zoomHome: function (e) { map.setView([lat, lng], zoom); },
_createButton: function (html, title, className, container, fn) { var link = L.DomUtil.create('a', className, container); link.innerHTML = html; link.href = '#'; link.title = title;
L.DomEvent.on(link, 'mousedown dblclick', L.DomEvent.stopPropagation) .on(link, 'click', L.DomEvent.stop) .on(link, 'click', fn, this) .on(link, 'click', this._refocusOnMap, this);
return link; },
_updateDisabled: function () { var map = this._map, className = 'leaflet-disabled';
L.DomUtil.removeClass(this._zoomInButton, className); L.DomUtil.removeClass(this._zoomOutButton, className);
if (map._zoom === map.getMinZoom()) { L.DomUtil.addClass(this._zoomOutButton, className); } if (map._zoom === map.getMaxZoom()) { L.DomUtil.addClass(this._zoomInButton, className); } } }); // add the new control to the map var zoomHome = new L.Control.zoomHome(); zoomHome.addTo(map);
const attribution = '© OpenStreetMap contributors'; const osm2 = new L.TileLayer('https://{s}.tile.osm.org/{z}/{x}/{y}.png', { minZoom: 0, maxZoom: 13, attribution, id: 'mapbox/streets-v11' }); var miniMap = new L.Control.MiniMap(osm2, { toggleDisplay: true }).addTo(map);
Au départ du Centre spirituel Notre Dame de la Justice, idéalement situé en bordure de la forêt de Soignes, nous organisons régulièrement des marches-prières d’environ 15 km.
Le matin, nous marchons en silence avec un texte proposé à la méditation.
Dès le midi, nous échangeons dans la convivialité.















