From 92625bb842d80faa33188306b918f2078c91e848 Mon Sep 17 00:00:00 2001 From: Kumar Damani Date: Tue, 26 Feb 2019 22:17:53 -0700 Subject: removed unnecessary db call breaking homepage due to db update --- web/public/javascripts/map.js | 33 +-------------------------------- 1 file changed, 1 insertion(+), 32 deletions(-) (limited to 'web/public/javascripts') diff --git a/web/public/javascripts/map.js b/web/public/javascripts/map.js index 44fba38..414efee 100644 --- a/web/public/javascripts/map.js +++ b/web/public/javascripts/map.js @@ -8,45 +8,14 @@ L.tileLayer('https://stamen-tiles-{s}.a.ssl.fastly.net/toner-lite/{z}/{x}/{y}{r} attribution: 'Map tiles by Stamen Design, CC BY 3.0 — Map data © OpenStreetMap contributors', subdomains: 'abcd', minZoom: 0, - maxZoom: 20, + maxZoom: 13, ext: 'png' }).addTo(map); // Create point feature for somewhere downtown var myDataPoint = L.marker([43.6529, -79.3849]).addTo(map); -// Create line feature and add style and add to map -var myDataLine = L.polyline([ - [43.6529, -79.3849], - [43.6531, -79.3855]], - {color: 'red', weight: 10}).addTo(map); - -// Create area feature add style and add to map -var myArea = L.polygon([ - [43.650948, -79.385655], - [43.66, -79.388], - [43.6634, -79.4011], - [43.66, -79.4011]], - {color: 'blue', weight: 4}).addTo(map); - // Bind popup to Data Point object // myDataPoint.bindPopup("This is my city"); // i can add regular html to this too - neat! myDataPoint.bindPopup("

City Hall (not really)

Toronto, ON
Information about city hall.

"); - -// Bind popup to area object -myArea.bindPopup("U of T Campus (not really)"); - -// Create an Empty Popup -var popup = L.popup(); - -// Write function to set Properties of the Popup -function onMapClick(e) { - popup - .setLatLng(e.latlng) - .setContent("You clicked the map at " + e.latlng.toString()) - .openOn(map); -} - -// Listen for a click event on the Map element -map.on('click', onMapClick); -- cgit v1.2.3