An Open-Source JavaScript Library for Mobile-Friendly Interactive Maps

learn more… | top users | synonyms (1)

0
votes
1answer
1k views

Bootstrap navbar and leaflet zoom controls

I'm using the THE MAP GUY(DE) Bootstrap temple and applying it to leaflet using the code below. The issue I'm having is that the zoom-control doesn't toggle right on page load. It will only after ...
0
votes
0answers
2 views

FeatureOver / FeatureClick event conflict in Leaflet

Currently, on http://velo300.free.fr/debug, first i set a sidebar toggle on feature click using leaflet-sidebar plugin. It works perfectly. Then i tried to set a function to highlight feature on ...
1
vote
0answers
10 views

32-bit Map tiles for use with leaflet

I've got a lot of single-band Geotiff files with the GDT_Float32 format and I need to present these over the web, hopefully using a webmap leaflet/mapbox/googlemaps widget where clients can hover over ...
1
vote
0answers
7 views

how change image of marker in leaflet

This is the code; it works very well but the marker image is not displayed. What can be the problem ? //**************************************WFS****************************************************// ...
1
vote
1answer
21 views

Leaflet display only clicked element of a loaded map layer (polyline)

I am creating a web mapping application that will return appropriate routes based upon ST_length query on a cartoDB dataset. So far, the code below successfully maps those routes with individual ...
0
votes
1answer
51 views

dynamicMapLayer esri-leaflet does not return properties of point data

I am using a dynamicMapLayer with point data. If I bind a custom popup to this layer, it does not return the properties for the point. https://plnkr.co/16IooEUXpoo9fvqlfnhU If I use polygon data ...
0
votes
3answers
458 views

How to load geojson from geoserver to define a variable in leaflet?

How can I load a geojson file from geoserver in leafletjs? There are lot of suggestions out there, but none of them work for me. Currently my app loads a js file from the server that starts like ...
-1
votes
0answers
9 views

Using Leaflet Marker Cluster with Turf [on hold]

Has anyone had success with using turf with MarkerCluster? I would think since both include functionality for L.marker they would but would like to confirm.
0
votes
0answers
27 views

Loading WFS from Geoserver to Leaflet

I use GeoServer 2.7.0 and Leaflet-0.7.7 and the jquery: <script type="text/javascript" src="http://code.jquery.com/jquery-1.9.1.js"></script>` for showing a WFS in my Geoserver. How do ...
0
votes
0answers
9 views

How to apply Mapnik Zoom Level Styling via Leaflet Zoom Levels

I've setup a node mapnik server to render some tiles for polygons. The application I've built to call out to these tiles is in Leaflet An example of a current mapnik styling rule is below <Style ...
2
votes
1answer
21 views

CartoDB SQL API styling individual polyline returns

I am creating a web mapping application that will return appropriate routes based upon ST_length query on a cartoDB dataset. So far, the code below successfully maps those routes (and clears any ...
2
votes
0answers
23 views

Leaflet filter on geoJson properties : multiple criteria

I'm using Leaflet filter on geoJson data. I'm able to apply it with a simple criteria : filter: function(feature, layer) { return feature.properties.field1 == "yes"; } I want now to apply it ...
0
votes
0answers
9 views

WMS Layers from Azure Geoserver not loading with multiple users

I am loading multiple WMS layers into a leaflet web application from an Azure virtual machine Geoserver that pulls data from a PostGIS database on the same machine. The layers load through quickly ...
-3
votes
0answers
22 views

How configure a search button in leaflet map [on hold]

I have created a web-map based on leaflet with support of QGIS and qgis2leaf. I have a table with: name, surname, city, job, but I don't understand how to configure the search button. I want to ...
2
votes
1answer
66 views

How to rotate an embedded web map (on pc)?

I was looking through a couple of maps I made, the maps were created by serving VectorTiles through TileStache and using Leaflet and Tangram (on respective pages) to render them. One of the reasons I ...
0
votes
0answers
15 views

Centering Leaflet Map on Website [on hold]

Should be really simple but I just can't seem to get it to work. How do I get my map to display in the center of the webpage? I put tags around the div id line and that works but it also centers the ...
0
votes
1answer
25 views

Is there anyway to combine a static geojson and data from database then display it in leaflet?

I do have a web map application that can load geojson then display it on leaflet map, however I encountered unresponsive script whenever I refresh my page due to big size of geojson. Is there anyway ...
2
votes
1answer
37 views

Leaflet: Map tile request, hidden key/secret via proxy

I would like to request a Leaflet tilelayer without exposing my API key and secret. For example, using the UrtheCast API (but would apply to other similar APIs that embed api_key and api_secret in the ...
0
votes
0answers
22 views

ordering overlays in layerControl

I have an application that adds GeoJSON to a map at various times. When the map loads I add a number of administrative boundaries. However, the user is able to query a database to get lat-longs that I ...
3
votes
1answer
362 views

Leaflet.label and MarkerCluster problem with zoom dependent add/remove layers

Here's the setup: I have a leaflet map with point data, to which I have applied leaflet.label and leaflet.markercluster. I add the clustered point data at a particular zoom level (code below). All ...
0
votes
1answer
28 views

Add and later access Leaflet.draw polyline index and a new property value

I am using the Leaflet draw plugin located at https://github.com/Leaflet/Leaflet.draw and what I want to do is when a person draws a new polyline to print in the console the index number of that ...
0
votes
1answer
25 views

Problem with missing tiles in a WMS Service Layer on Leaflet Map

When we load a WMS service in our Leaflet maps, we encountered tiles that do not show. You can see this happening on the following Plunker if you zoom in and pan to the left or right. ...
1
vote
1answer
33 views

Problem with Leaflet Control Layers using Vector Layers

I'd like to add a Vector Layer and configure it in a Leaflet Map with Leaflet Control Layers. The code is ... <!DOCTYPE html> <html> <head> ...
0
votes
1answer
28 views

CartoDB Core with Leaflet

I just recently experimented with CartoDB. I have an existing Leaflet Map with lots of Plugins and dependencies. Just adding the CartoDB.js does not work (I think there is a version conflict, but I am ...
0
votes
1answer
30 views

Leaflet - Load markers in the current map - dynamically

I am looking for a marker plugin for leaflet that allows loading of markers dynamically, according to the current view. E.g. I want to add OSM POIs to a world-wide map. Obviously loading all at once ...
1
vote
1answer
33 views

Folium and MarkerCluster?

I'm trying to use Folium but am having difficulty adding multiple points to a MarkerCluster in one fell swoop. Documentation is... sparse, so I'm not sure how to proceed. This recreates the problem ...
0
votes
2answers
1k views

How to export to all points within Leaflet polygon?

Is it possible to export all points within a polygon drawn using Leaflet? (http://leaflet.github.io/Leaflet.draw/).
2
votes
1answer
210 views

Leaflet removing labels when any popup window is shown

I am newbie to leaflet and i found the following solution to add static labels to features in my map: L.CircleMarker.include({ bindLabel: function (content, options) { if (!this._label || ...
1
vote
2answers
244 views

Geocode free APi for internal application

I need opinions / experienced use on this issue: Which API can be used to geocode an internal application of a company that meets these requirements: Can be used for company internal application ...
0
votes
1answer
49 views

Adding shapes and/or icons to legend using Leaflet within R?

Is it possible, using Leaflet within R, to make a legend in such way that includes a set of icons or shapes and their corresponding value?
2
votes
1answer
213 views

Showing link for every city at different zoom levels using Leaflet?

I have a Leaflet map that I am using to render a map of the U.S. The map will have specific zoom levels. For example, when the map first loads it will show major U.S. cities. Then if you zoom in it ...
2
votes
1answer
411 views

Leaflet custom div & click propagation on other elements

I've gotten custom HTML applied successfully within my #map element (where Leaflet is appended) but I'm having unusual behavior with other Leaflet objects that find themselves within the transparent ...
0
votes
1answer
37 views

How to display geotagged photos from my domain in leaflet

I already asked a question similar to this then I used a plugin of displaying geotagged photos in leaflet from (Google+ photos|Instagram / CartoDB|Norvegiana ) photos in leaflet This plugin gets ...
-1
votes
0answers
15 views

Encrypt my JS Leaflet code [closed]

I build a small GIS interface with leaflet now I have to give it to the client to host it in their domain I want to protect my code kind of encryptien or something ...
2
votes
1answer
32 views

Add Links to Leaflet Choropleth Map

I'm making a choropleth map based on this example I would like to add links to the map, so that when a user clicks on a state they will be taken to a specific page. For example, a user clicks on ...
0
votes
2answers
39 views

How to load a vector tile layer in a Leaflet map?

I need to load a vector tile layer in a Leaflet map. The vector tile is the vector tile layer about Mapillary sequences (look at https://a.mapillary.com/#vector-tiles ...), and the tile URL pattern ...
0
votes
1answer
25 views

Mapillary Vector Tiles are not shown at every zoom levels in a Leaflet map

I'm trying to load the Mapillary vector tiles layer in a Leaflet map. I'm using Leaflet.MapboxVectorTile (ref. https://github.com/SpatialServer/Leaflet.MapboxVectorTile). Here you are my code ... ...
0
votes
1answer
26 views

Use of Leaflet plugins in 'Leaflet for R' to connect with ArcGIS online

I was wondering if it is possible to use the plugins for the normal (non-R) version of Leaflet, and if, how I can do that. reason I need to do that is, that some of the data I need to show are hosted ...
2
votes
2answers
47 views

Esri leaflet feature layer toggle question

I have a feature layer that I am trying to toggle on / off via click. The problem I am having is that if I toggle the layer on and then off, it does not update to the screen unless I zoom in / out and ...
0
votes
1answer
24 views

Leaflet Basemap and Overlay Display

When running this why does the open street layer not show up as the base layer by default? and why does the precipitation layer come up as already checked to display? None of the other overlays ...
1
vote
1answer
190 views

CartoDB JSONP callback in leaflet-search plugin

long time reader, first time question-asker etc... So I'm trying to implement a search function on an app I'm building using data from cartodb in leaflet and this leaflet-search plugin: ...
1
vote
1answer
250 views

Pass coordinates parameters to geoserver pgrouting service from Leaflet wms tile layer

I've configurated a pgRouting service in Geoserver, following the steps on the documentation it's easy to accomplish. Reading the documentation, existing examples, etc.. I've come to undestand how ...
1
vote
1answer
34 views

Add DEM layer to Leaflet

I want to add a digital elevation model (DEM) layer to my leaflet map and access the height data through javascript, i.e. I cannot use .png files or qgis2webplugin but rather .tif or some compressed ...
1
vote
1answer
160 views

Leaflet + GeoServer + British National Grid

I have followed along some examples and was able to display BNG 27700 data nicely on the map, however now I want to perform getFeatureInfo function on click. Again the code I used is as below: var ...
0
votes
0answers
31 views

Cannot draw two layers at once using Leaflet

I have two map layers that I want to show at once: One is the full data, the other is a filtered version of the data. The map will draw with each of these layers, but not with both at the same time. ...
3
votes
2answers
4k views

Make sidebar div active on Marker click (and vice versa)?

What's the best way to change an element to active when you click on a marker. For example, when you click on a marker on a Leaflet map, how to make it so the sidebar element that's related to it ...
54
votes
6answers
31k views

Should I use OpenLayers or Leaflet?

I was debating with one of my collegues on OpenLayers v/s Leaflet. I made a point that OpenLayers is much better API if we wish to build a project, where you need direct connectivity to the Geoserver ...
1
vote
1answer
1k views

How do I add elevation data to a GeoJSON line from a GPX file?

I understand that elevation can be added as an optional third value in Coordinates (lat, long, elev) in a geojson file, but I can't find a way to actually do that from a gpx file. I've used ogr2ogr to ...
2
votes
1answer
227 views

Draw heatmap only over water layer using Leaflet?

I need to draw a heatmap, but only over water because I want to represent water heat level. I am using Leaflet. How can I do it? I found an only-water layer, maybe it would be usefult for developing ...