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

learn more… | top users | synonyms (1)

4
votes
1answer
160 views

GeoJSON Layer Order In Leaflet 0.7.5

I am developing a web application that brings in a number of tileLayers and geoJSON layers. For the tile layers I have been able to do similar to this JSFiddle in that the layers appear depening on ...
0
votes
1answer
47 views

Visitors to city's website can digitize points? [duplicate]

I'm trying to collect input on a revision to my town's mainstreet. Is it possible to create a map where a visitor can click a point, and answer a few questions about that point? (OK I was told that ...
1
vote
2answers
341 views

Applying a single leaflet search control to search multiple layers?

I am attempting to add a single search button to look through geoJSON layers. They will look through the field "name". Unfortunately, my method of creating a layer group is not working. What am I ...
0
votes
1answer
154 views

Can't enable Jsonp in Geoserver 2.7.0 and then publishing my WFS request in Leaflet

I'm working on localhost:8080 and want to get WFS data in a Leaflet map. So, I've read in some posts here that I first I have to enable Jsonp in my web.xml file in Geoserver. So I put <context-...
1
vote
0answers
64 views

Leaflet.js setBounds, scaling

I'm using leaflet.js to create a map of Scotland, with two insets for the Orkney and Shetland groups of islands. This is as far as I've got. I wish to guarantte that no matter what size the overall ...
1
vote
2answers
191 views

Separating two GeoJSON files, one with properties and another with geometry?

Using Leaflet with GeoJSON, I would like to create a map with geometries, and with alphanumerical data associated to each item of the geometry. A map very similar to the easy sample at http://...
0
votes
1answer
232 views

How to select layer by default : leaflet

I am working with the leaflet, where we first load the imageoberlay to the map using user input. Now, i been trying different methods to select that layer by default. The problem is only that the ...
0
votes
1answer
103 views

Leaflet Search for GeoJSON creating duplicate, non-functional buttons

I added a plugin for searching a GeoJSON file in leaflet, but now there are multiple search buttons and they do not recognize any input. I suspect that it is initializing for every single instance of ...
1
vote
0answers
132 views

How to pass custom marker to polyline decorator

I am working with leaflet appliction, where user draw some shape. A polyline added to that shape using leaflet.polyline.decorators. I just want to know how to pass custom marker to L.Symbol.marker(). ...
0
votes
1answer
163 views

Clickable hyperlink from GeoJSON field in feature

How do I make a URL a hyperlink when the information is called from a GeoJSON field? I have tried adding html tags, but since the link is not in-line, it does not work. (Script below) LOC_Catalo is ...
0
votes
1answer
183 views

Activating Search Plugin with JS Leaflet

I am attempting to add the following plugin to search a GeoJSON file I have open in Leaflet Javascript: http://labs.easyblog.it/maps/leaflet-search/examples/geojson-layer.html I have brought in the ...
0
votes
1answer
99 views

Do all open source web mapping platforms require programming? [closed]

I currently use a proprietary software product for my company's web mapping, however I am interested in seeing other products. I use QGIS and would like to to put my layers on the web for both ...
0
votes
0answers
68 views

ClearLayer() not working for polyline Decorators

I am working with leaflet api, where user draw shapes on images. Clearly i am having problem with polyline decorator because clearlayer method doesn't seem to work for decorators, might be a bug ...
0
votes
0answers
111 views

How to stop polyline decorator marker displaying on map but image layer

I am working on application uses the leaflet api Live Here User must enter "1" in alert input field to use the application. Introduction Application has some controls to draw different shapes on ...
0
votes
0answers
76 views

WFS query against SQL Server - Returned results not restricted by query

I have an SQL Server 2012 table, which contains a DbGeometry column with a spatial index. Then a Geoserver 2.7 using it. The problem is that when I do a WFS query it doesn't restrict the results to ...
3
votes
1answer
51 views

Use custom dataset for routing

I'm looking to substitute my own dataset with OSM data in Leaflet Routing Machine or another routing tool. Is this possible?
0
votes
1answer
192 views

Leaflet Layer Visibility Checkbox

I have created this JSFiddle OpenLayers map that toggles the layers visibility using the bootstrap-switch. I am looking to achieve the same with leaflet but can't seem to get the equivalent of the ...
1
vote
0answers
77 views

Selecting leaflet markers based on Json features [closed]

I have data coming from a Json file and I created a layer based on this Json file using markerClusterGroup. I am hitting the wall trying to do two things: 1 - Select some markers based on some Json's ...
2
votes
3answers
267 views

Custom Styling OpenStreetMap without needing to host it yourself

I know it's possible to edit the way in which OpenStreetMap display, with CSS-like (like MapCSS) stylesheets. Is possible to do this without having to host your own tile server?
2
votes
0answers
37 views

How to place image between two marker using css : leaflet

In my application where i use leaflet api, i am able to put two gate markers and polyline drawn between them. Here, i just wanted to find out the way to put the image from css on the polyline which ...
1
vote
0answers
32 views

Drawings not visible after removeLayer method : leaflet

Introduction As i am working on application which uses leaflet api. Live Here Where first user enter '1' as input to load the image on map. Then user can draw different shapes(fences) using bottom-...
0
votes
1answer
460 views

How do I show feature attributes in a Leaflet popup?

So I have a JSON file displayed on my leaflet webmap. I would like to have it so a popup will appear when a feature is clicked. Right now it is a polygon feature. How do I call up information from the ...
2
votes
3answers
107 views

get external jsonp and convert coordinates in leafletjs

I need to solve two problems: convert my coordinates from wgs84 to epsg28992 use external geojson from an jsonp url Both problems are as far as I understand not supported by Leaflet itself. So I ...
2
votes
1answer
172 views

Leaflet search GeoServer layer

Let me start off by saying that I'm new to web mapping, but I've managed to put together a fairly simple web map using Leaflet: http://www.hcswgis.com/globalmapper/ It has most of the functionality ...
0
votes
0answers
98 views

Changing tooltip layers with leaflet/mapbox

I'm a relative beginner with leaflet/mapbox but we are building a website with a set of different TileMill layers, each of which have different interactivity. We had been switching layers with L....
2
votes
1answer
196 views

How to apply css on polylines : leaflet

I am working with the application which uses leaflet api. Introduction I needed to draw different types of fences, using decorators i can somewhat apply good visuals to the polylines but not much. ...
0
votes
0answers
60 views

How to get the directions of the co-ordinates in leaflet?

Now i'm working on the live tracking to track my vehicle.I want to get the directions to change the marker position based on the co-ordinates. I have using arrow icon for marker icon. I need to ...
3
votes
2answers
89 views

Get tile layer intensity at given zoom and longitude/latitude (Leaflet)

I can display a tile layer as an overlay in Leaflet via an url of the form path/to/my/tile/layer/{z}/{x}/{y}.png : my_overlay = L.tileLayer('http://path/to/my/tile/layer/{z}/{x}/{y}.png', { maxZoom: ...
3
votes
3answers
75 views

Leaflet - tell whether an object a layer or a group

I need to close popups on an object, but I don't know whether it is a layer or a geoJSON (and hence a feature group). If the former, I can do layer.closePopup(), but if the latter, I have to do layer....
1
vote
2answers
124 views

Load geojson files from a dropdown list

I would like to load geoJSON from a dropdown list. Everything i found was internal plugin for leaflet such as leaflet-geojson-list. I have a html dropdown list but I don't know how to link my geoJSON ...
1
vote
1answer
77 views

Problem with legends, leaflet

I am not very good at js and new with leaflet so i my code may be a bit messy but stil... I have a problem with my legends, i have 2 legends and many overlays and i want some legends to be "linked" ...
0
votes
1answer
268 views

Leaflet : How to update polyline ? Live Tracking

var ColorVar = '#bd0026'; var firstpolyline = new L.Polyline(polyList, { color:ColorVar, weight: 8, opacity:0.8, smoothFactor: 1 } ); ...
0
votes
0answers
30 views

How To create a OpenLayers-Control from existing Leaflet-Plugin

I already asked a question on Stackexchange that no one could answer: MarkerCluster Animation for OpenLayers2 with Lines So I would now like to know if someone has already used a Leaflet-Plugin to ...
2
votes
1answer
669 views

installing geojson-vt with Leaflet

Super rookie question I'm sure, but I need help using the leaflet plugin geojson-vt. According to tutorials, like this one on http://bl.ocks.org/Sumbera/c67e5551b21c68dc8299, there should be a js file ...
0
votes
1answer
134 views

Use lamber 93 imageOverlay with leaflet on top of OSM tiles layer

I'm trying to use a lambert 93 image overlay on top of an Open Street Map title layer. var map = L.map('map'); L.tileLayer('http://{s}.tile.osm.org/{z}/{x}/{y}.png', { }).addTo(map); var coords = { ...
0
votes
1answer
357 views

Bootstrap and Mapbox: Nav Bar layer selection

I am building an interactive mapping solution for my employer and have run into a bit of a hangup. I am working with bootstrap for the first time and cannot figure out how to link the dropdown list ...
0
votes
0answers
59 views

Setting maxbounds in leaflet according to WFS / WMS layer bounds

A leaflet map has the option to set the maximum bounds a user can pan it. I'd like to set these bounds dynamically (i.e. setMaxBounds method) according to the bounds of a given WFS layer. The goal is ...
0
votes
0answers
68 views

Web mapping application with select/unselect features and receiving names of selected features on map

I am creating web application that need to have the following functionality: display polygonal features on the map (about 20-50 Mb if GeoJSON) on click on feature - select them and view names ...
0
votes
1answer
299 views

How to draw a rectangle on a Leaflet map from GeoJSON data

I am trying to draw a rectangle on a Leaflet map with JSON data which looks like this. var geojsonfeatures = {"type":"FeatureCollection","features":[ {"type":"Feature", "geometry":{"...
0
votes
1answer
76 views

resetStyle in geoJSON pointToLayer circleMarkers

I am creating a geoJSON layer, with pointToLayer returning circleMarkers. In that layer's oneachfeature, I am triggering a style change on hover, and this works fine. However, I cannot reset the style ...
0
votes
0answers
69 views

Does Leaflet handle TopoJson in OSGB EPSG:27700 projection?

I already have a Leaflet map showing custom base map tiles in British OSGB projection, EPSG:27700 (using the Proj4Leaflet plugin). I would like to overlay some nationwide admin boundary data in the ...
0
votes
0answers
123 views

Box zoom out in leaflet maps

I am using leaflet for creating maps in web and geoserver for serving maps as WMS layer.Leaflet has box zoom-in tool when we click shift and drag on the map. Similarly I need box zoom-out in ...
0
votes
0answers
27 views

Leaflet GeoJSON ignores first clicks

I have a functioning Leaflet map. In order for the click event to work I have to click on the area that has the event then click on an area without an event then click on the area with the event to ...
0
votes
1answer
209 views

switching the layers on/off in leaflet map layer tree based on styling

I am developing web application which has leaflet maps. I need the layer control which is similar to QGIS I am using Geoserver to get the layer as wms format and I added that layer using tilelayer....
1
vote
2answers
168 views

Adding properties to pop ups in leaflet maps

I have a leaflet map which display pop-ups that give the name of a country when clicked. How can I add additional properties and have them all displayed, similar to this map http://lotrproject.com/map....
0
votes
4answers
341 views

Leaflet Layer Control not visible

What am I doing wrong here? Everything is working fine, except that the layer control is not showing at all.. hhLayer and wpLayer are L.geoJson(); in case that helps. <script type="text/javascript"...
0
votes
0answers
56 views

How to calculate pixels on latlng base: leaflet

I am working with the leaflet api.Where User draw a polyline and latlongs saved in variables. I been looking for a leaflet function which suppose to take latlongs and calculate pixels.Found the ...
0
votes
1answer
105 views

How to implement close Popup for Multipolygon?

I am closing the popup for geoJson (layer.closePopup()) to make a modal to appear. The function works fine for regular geometry but fails for Multipolygon. I get the error - ClosePopup is not a ...
0
votes
3answers
91 views

EsriLeaflet - Problem with special german projection

I got a service with EPSG:3068 (http://epsg.io/3068-15949) My test code to diplay this service on an Leaflet Map with Esri-Leaflet is as following: <!DOCTYPE HTML> <html> <head>...
1
vote
2answers
175 views

Loading Json properties in a popup using leafletjs

I have a geojson file (tide_gauges.geojson) { "type": "FeatureCollection", "crs": { "type": "name", "properties": { "name": "urn:ogc:def:crs:OGC:1.3:CRS84" } }, ...