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

learn more… | top users | synonyms

0
votes
1answer
42 views

fitBounds on points after feature selection

I am trying to follow some of the examples I have found here and in Google Groups about fitBounds for points. Most of the examples are for polygons and don't seem to work for points. I think I've ...
2
votes
1answer
143 views

How to get data from TileMill tileLayer properties in Mapbox for click/hover

I've successfully used Leaflet to load a geoJSON polygon-shapefile with data, and added click and hover interactivity to the layer. For a large dataset, I switched to mapbox.js 1.6.1, used TileMill to ...
3
votes
1answer
2k views

CloudMade Routing with Leaflet: route is not displayed

I am trying to consume the CloudMade routing API using Leaflet. So far, I have managed to pass points and receive a response, and parse that response into an array of points. The array of points is ...
4
votes
1answer
158 views

Editing PostGIS topology in a web browser

I am trying to conceptualize the best process for editing topology from PostGIS in a web browser. Ideally what I would like to accomplish is the loading of a topology (imagine the lower 48 states of ...
0
votes
1answer
98 views

How to compute and add the bounding box for every feature in a given geojson file

I have a geojson file. I need to find the bounding box of every feature in the geojson, then find the intersections between any two bounding boxes. I am using leaflet and Angular to display the ...
0
votes
0answers
8 views

using gzipped js files in windows 8 OS

Previously, we were using a private ISP to run our web site. They were using LINUX. We could use js.gz files to serve interactive maps. Now, we have our own server with Windows 8 OS. How we can serve ...
0
votes
1answer
33 views

CartoDB.js SQL API editing geometry

Is there anyway you can allow users to edit the geometry of shapes (e.g. move an existing point) using the CartoDB.js or CartDB SQL API libraries. I realise you can do this directly in the CartoDB ...
0
votes
1answer
381 views

PHP-MBTiles Server implementation with Leaflet and Wax

Using PHP tile server from infostreams with Leaflet and Wax Connector for Leaflet to visualize my .mbtiles. I upped the source and the .mbtiles on a free hosting service. I am getting a blank Leaflet ...
5
votes
3answers
148 views

Guidance when to style your features in Tilemill vs. Leaflet?

I've found this generally to be dependent on each project's goals (or what the client wants), but when you have the options, what any rules of thumb or guidelines do use you in a project to determine ...
0
votes
1answer
180 views

TypeError in leaflet on zoom in or out

I am working on an application that renders land parcels from PostGIS as polygons in Leaflet. I have an event handler set for 'viewreset' on the map: this.leaflet_map.on('viewreset', ...
2
votes
1answer
747 views

UTM Grid as a Layer with Leaflet

How can I display a UTM Grid as a layer with Leaflet? Search a way to embed a OpenStreetMap map with Leaflet in a website. Particularity. I want to display a UTM Grid as a Layer. In addition, lower ...
0
votes
0answers
37 views

Radius based search with Leaflet maps

Using leaflet I have created a simple map, played around with markers (adding/removing) and have added some GeoJSON data polygons etc. I now need help with implementing a radius search. For example I ...
2
votes
1answer
228 views

leaflet geojson contextmenu

I want to add a context menu on right click for various elements on my geojson layer (I'm doing a road map so on a right click on the road at any part I want to show the context menu). I've managed ...
0
votes
1answer
38 views

Millions of polygons: displaying layers in Leaflet based on location being viewed?

I'm trying to create a map of all parcels in a state. In my state, this is several million parcels. In their current format, they are encoded as topojson and divided up by county. I'd like to show ...
6
votes
3answers
186 views

How to generate image tiles from custom geo data for use with Leaflet

Migrating a webapp from Google Maps API V3 to OSM + Leaflet, which displays custom data that consists of lots of lines and points, on a background map. When this custom data is drawn by Leaflet on ...
1
vote
2answers
304 views

Polygon intersection with bounding box with polygon's holes intact

I am trying to serve GeoJSON FeatureCollection tiles with each feature's geometries trimmed to the tile boundary. I am working on a Leaflet plugin to re-assemble the geometries. It works by building ...
2
votes
1answer
19 views

Is it possible to use two layer.bindPopup functions in Leaflet

I have two different layers in a leaflet map. I have one layer in which I would like the popup to return some text from the layer's attributes. They other layer I would like the popup to return an ...
1
vote
2answers
784 views

how does one reset map.fitbounds (zoomtofeature()) to the original zoom?

I have a lovely map setup using Leaflet with MapBox tiles (only). It is a United States map with polygons for each state with an onclick event to zoomToFeature. The basic zoomToFeature() function ...
1
vote
2answers
132 views

Is there a Cluster convex hull implementation in OpenLayers?

In this leaflet example. When hovered over a cluster marker, it shows the bounding area of the clustered features which is known as convex hull. Is there a way to reproduce it with OpenLayers?
2
votes
0answers
76 views

QGIS 2.0 How to copy the color styling to a color column in a layer's attribute table

I have a polygon layer in QGIS that I have applied a random color style to each polygon. Under Layer Properties -> Style I selected a Categorized style and then generated a random color ramp. I added ...
1
vote
2answers
62 views

Leaflet highlight feature by ID

I have a map application where: I load polygons as GeoJSON objects I draw all polygons in a single layer I highlight a polygon on mouse hover What I need to do is the following: on mouse hover, I ...
2
votes
1answer
487 views

How to keep bound popups from opening on [click]?

I am working on a map application which creates and binds popups on markers and polyline objects. The popups are created and bound lazily, i.e. ad-hoc when a user clicks on a specific object. The ...
1
vote
1answer
42 views

labels showing up behind other labels due to unmatched z-index

I am using leaflet label plugin to show labels on markers by using layer.bindLabel('name'). As the number of markers is high the markers come above the label thus labels are not visible clearly. ...
1
vote
2answers
630 views

How I can load tileLayer in Leaflet framework using local tiles?

I'm using file:///C:/path/tiles/{z}/{x}/{y}.png like url of tileLayer but it doesn't work and no error is shown. var layer = new L.tileLayer("file:///C:/OSM/tiles/{z}/{x}/{y}.png", { minZoom: ...
0
votes
1answer
47 views

Reproject WKT Polygon with Javascript

I have a polygon in WKT in EPSG:4326: polygonWKT = 'POLYGON((13.215179443359373 52.588032137196755,13.42803955078125 52.592620721000365,13.454132080078125 52.46897854656702,13.347015380859375 ...
2
votes
3answers
8k views

How to draw a polyline in Leaflet?

This is my coding I used in Leaflet: var pointA = new L.LatLng(28.635308, 77.22496); var pointB = new L.LatLng(28.984461, 77.70641); var pointList = [pointA, pointB]; var ...
0
votes
1answer
57 views

Show map using esri leaflet, with 4326 spatial reference

I have this MapServer http://geoservices.big.go.id/arcgis/rest/services/RBI/Rupabumi/MapServer It turns out it uses 4326 spatial reference. I want to present it using leaflet, my code so far: ...
2
votes
3answers
90 views

Start-Marker from geojson polyline

i have a map with some walking- and bike-routes and popups with a few details and a picture. Now i want to set a marker on the first vertex of a geojson polyline, but i cant find out how. Btw. i´m ...
0
votes
1answer
40 views

CartoDB or Leaflet.js get coordinates of point clicked?

Using CartoDB or Leaflet.js is it possible to retrieve the coordinates of the point on the map clicked when opening an infowindow?
0
votes
1answer
48 views

Zoom variable or pixel distance

I have query by distance working in a framework that generates a list of features within a fixed distance of a clicked feature. I would like to make the queried distance variable based on either: ...
0
votes
1answer
61 views

Displaying properties from GeoJSON file in choropleth map Leaflet.js

I'm using the Leaflet.js library to generate a choropleth map of zip codes colored by some property values stored within an externally loaded GeoJSON file. I'm following a tutorial here but have run ...
1
vote
1answer
50 views

PostGIS: Update child geometries based on parent

I'm using Leaflet and postgis in a case where using Leaflet draw plugin I draw a polygon first like this Now, I draw a line which cuts the polygon and using line and polygon geometry, based on ...
0
votes
0answers
20 views

Can i access UTF grids without a server?

I'm creating a slippery map that will run off of a usb stick or cd (client request). I'm able to load up the map, display pre-cooked tiles and some some simple vectors. The client would like some more ...
0
votes
1answer
57 views

Zip Code-Level Choropleth Using Leaflet.JS

Brand new to Leaflet.js, but I'm enjoying learning it. However, I have a question I've been working on that even the Google hasn't been able to answer just yet. Is it possible to create a choropleth ...
1
vote
1answer
302 views

Looking for a GeoJSON describing the french departments

Is there any place where I could find a GeoJson describing the borders of the french departments, or do I have to convert a .shp file?
1
vote
0answers
38 views

Can't project ArcGIS Tiled Service for Esri-Leaflet

I'm following this example from the esri-leaflet docs. I have an ArcGIS Tiled MapService in ESRI:102696. So I'm trying to use Proj4Leaflet to project the service and use it in my application. I ...
1
vote
1answer
25 views

Delay on Marker Title in Leaflet

I am trying to put title on leaflet markers. This explains the way to give title to marker which would appear on hover. Is there any way we can set time on that i.e. make the title appear after 50ms ...
0
votes
0answers
17 views

Can tilecache create UTFgrids?

Am i able to create utf grids in tilecache or do i have to move to tilestache? I ask because i am using, and would prefer to continue to use, utmZ10 and not wgs84 or spherical mercator.
0
votes
0answers
31 views

How to access map tiles from external storage in PhoneGap?

I am trying to build an Android app using Phonegap and Leaflet. I have added a local tile layer and added the tile folder within the www folder. It's working fine. var tmsLayer = ...
0
votes
0answers
21 views

Possible to call Telogis Geobase server from OpenLayers or Leaflet

I've been creating mapping solutions some time with various platforms and one I am currently working on is utilizing Telogis. I'm having a lot of trouble with their JS library, and it's not playing ...
3
votes
4answers
4k views

How to load external geojson file into leaflet map

I would like to load a geoJSON (polygon) file into my leaflet map. I have seen examples where geoJSON is embedded into the javascript code but I can't find any examples showing how it is done with an ...
5
votes
2answers
1k views

Leaflet Polyline with custom fill pattern

I'm drawing Lines with leaflet.js an have to create custom styled polylines. So i got various image files which should be like a repeated background image in HTML. So is it possible to give a drawn ...
2
votes
2answers
4k views

Custom Leaflet Controls

I have gotton some help in creating a custom control for leaflet, but I am still having trouble upgrading to the CSS styles used by the latest versions of Leaflet. Basically, all I need is a icon in ...
1
vote
1answer
112 views

How to get LatLng array from geoJSON Layer in Leaflet?

i need to hand the latlng coordinates from my phpPostGIS-served geoJSONLayer as an array over to a new added HeatMap Layer. L.geoJSON has an build-in option: coordsToLatLng( coords )" and a static ...
1
vote
2answers
60 views

Data structure: mongoengine to GeoJson

I recently posted my first question on StackOverflow, but I think the question was quite extensive and full of potential errors. So I'd begin again, step-by-step, with a much shorter and simplier ...
5
votes
6answers
956 views

3D perspective on maps in Leaflet, CartoDB?

Are there any JS library out there that would render normal, flat maps (like Leaflet) into a perspective map like this one, on the web: Also, anyone seen anything that could turn CartoDB data into ...
0
votes
0answers
21 views

Is there a way to convert L.circle to a geodesic polygon in Leaflet

Reference: How to make a predetermined Polygon (Circle) From 4 Coordinates, The Radius and Center Longitude and Latitude in Openlayers Openlayers uses this function : createGeodesicPolygon Question: ...
0
votes
1answer
38 views

Bootstrap3 Resize map height for phone

I have a leaflet map in a bootstrap 3 html application. I have content both above and below the the map which has a height of 600px. When I access the application from a phone, the width of the map ...
0
votes
1answer
78 views

Leaflet Custom Control Fails

Why does the myMenu control not respond to a click? var map = L.map('map').setView([51.505, -0.09], 13); L.tileLayer('https://{s}.tiles.mapbox.com/v3/{id}/{z}/{x}/{y}.png', { maxZoom: ...
1
vote
2answers
59 views

Adding multiple layers with timed delay in Mapbox/Leaflet

So I've got a Mapbox map showing data split into several layers. I'd like the user to be able to click a play button to call the function "gogogo", and then the layers get added one at a time every 1 ...