All Questions
Tagged with leaflet openstreetmap
559
questions
-1
votes
1
answer
1k
views
L.markerClusterGroup is not a function
I'm trying to use leaflet cluster markers. I created a template for a WP page.
First, I'm loading library and css :
<link rel="stylesheet" href="https://unpkg.com/[email protected]....
0
votes
0
answers
264
views
How to access a local directory instead of URL of OSM server?
I am playing with the Leaflet.html demo provided on their website to try and build a offline map application.
I am trying to change the following line of code
// add the OpenStreetMap tiles
...
1
vote
1
answer
88
views
How to set active region correctly in this Leaflet map?
I want to hightlight active region with nid=105. I did it in "color: feature.nid == 105 ? '#fa9f1a' : 'white'". But I have a problem, when I clicked to another region, region with nid=105 ...
1
vote
2
answers
2k
views
Is there a way to open a popup input text after a polygon is created in leaflet?
I'm trying to make a web app that uses leaflet to display a map, users should be able to draw and edit polygons over the map and they should have the ability to name each polygon they create.
I want ...
0
votes
0
answers
825
views
Tiles don't render or it takes too long
The problem:
tiles are being rendered extremly long time (1 day or never)
The question:
What to do to make tiles loading and loading quickly? How to solve this problem?
The description:
While trying ...
0
votes
0
answers
27
views
Leaflet - Zoom map to fit several circles leaves big gap on sides [duplicate]
On Leaflet, I have several circles in a map that I generate like this:
let allData = [
['Berlin', 52.5243700, 13.4105300, 'Germany'],
['Hamburg', 53.551086, 9.993682, 'Germany'],
...
2
votes
2
answers
749
views
React leaflet map location glitches when not in App.js
I am trying to use a Leaflet map in my React application but I am running into a strange problem. I tell my map to pan to the user's current geolocation (if they have allowed access to their location) ...
2
votes
2
answers
1k
views
map.getCenter and map.getBounds are not functions inside map.target.on('click') function
I am creating an app that makes use of the leaflet OpenStreetMap API but I am running into a problem. I am trying to get the center coordinates when I click my map, but i am getting the error: '...
2
votes
0
answers
324
views
How to overlay a satellite mbtiles over a regular OSM map?
I'm using klokantech tileserver gl to serve OSM maps. These maps are consumed by a frontend developed using Vue and vue-leaflet. The OSM world mbtiles file works perfectly with the default config from ...
3
votes
1
answer
4k
views
Use a local tile layer with leaflet
I'm creating a project with React and Leaflet.
This project will run offline on a computer connected to nothing, so I need to have the tile layer stored on the same computer (no tile server).
Since I ...
0
votes
1
answer
407
views
Mapping many data and drawing lines alone the roads on leaflet
I would like to do something like the traffic condition in Google Map in my web page, I use React and Leaflet (react-leaflet) in the front-end. I have millions points around the city, in the format ...
0
votes
1
answer
280
views
How to add municipalities to map?
I've successfully implemented a map of Denmark using Leaflet. However, I need to show the municipalities in Denmark, and this is surprisingly complicated.
On this page, I gather that there are Mapbox ...
2
votes
0
answers
406
views
Load large GeoJson files on demand on a leaflet map (checkboxes)
I have heavy Geojson files to display on a leaflet map. Because they are heavy, I would like them to be loaded only if the user checks a specific box on the map related to each of these Geojson files.
...
0
votes
1
answer
1k
views
React-Leaflet / OpenStreetMap: Detect if the marker is inside a circle
I have a marker and several zones (Circle). Now I want to detect if the marker is inside a zone. Any idea how I can do this?
data.json
{
"name": "John Doe",
"longitude&...
1
vote
0
answers
240
views
Leaflet bad performance with OverPassLayer Markers
Im currently encountering bad performance with my Leaflet Map while using the Overpass Library, especially when moving around on the Map although there are not a lot of Markers (less than 100). This ...
0
votes
0
answers
82
views
How to change the administrative borders for Crimea
How can make changes to display Crimea as part of Ukraine. For leaflet I can't find anything like it
0
votes
1
answer
2k
views
How to remove or empty the leaflet map based on the condition
I want to remove the map based on the selected condition.
.component.ts
dataChanged (selectsensor) {
console.log(selectsensor)
for( var j=0;j<selectsensor.length;j++){
for (var i =0; i< this....
1
vote
0
answers
466
views
How to add the text labels on the leaflet map
I want to show the text label to show the location name on the leaflet map(Not tool tip text, or popup text).
.component.ts
map[i] = L.map(v).setView([this.sensors[i].latitude,this.sensors[i]....
0
votes
1
answer
377
views
Openstreetmap , Leaflet.js: Open all popup box on page load alwayes
is there any way popup always stay open ? Not having the need to click on it to open.
Openstreetmap , Leaflet: Open all popup box on page load alwayes
my full JS code:
https://jsfiddle.net/82xvheqd/
...
0
votes
1
answer
411
views
moving marker does not exist on type of import
moving marker does not exist on type of import please help me to solve this error.
I have installed npm package npm install --save leaflet-moving-marker
but it shows the error
moving marker does not ...
0
votes
0
answers
73
views
Is there any tool or somehow to make a OpenStreetMap editor which can manage multi layer in it?
I need to build a web application that could draw, edit, import, export,.. map using OSM data. In that, I could add layers and manage like tree form. The layer can be toggled on/off on the map to edit....
0
votes
1
answer
503
views
Getting the error of map container not found in leaflet map
My requirement is to show the multiple leaflet maps(based on the backend data) on the page.
map.component.ts
for (var i = 0; i < this.mapleaf.length; i++) {
map[i] = L.map(this.mapleaf[i])....
1
vote
2
answers
991
views
How to create the multiple leaflet maps on the page in angular
I have created the leaflet open street map given below.
.component.ts
map = L.map('map').setView([12.876, 80.599], 12);
L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
...
1
vote
1
answer
776
views
How do I pull tiles from a custom OSM tile server? My URL string doesn't seem to be working
We have a custom OSM tile server set up on AWS and pointed to a subdomain URL. If I type the URL in a browser, the map appears fine.
Now I need to access the tile server, both with Leaflet and ...
0
votes
1
answer
407
views
Leaflet 1.7.1 popup on mobile Bug
I am working on a new Leaflet map with 1.7.1.
I noticed on my mobile device browsers (on Safari and Chrome) that the popups are flickering (not displaying/not showing up). I went on the Leaflet ...
2
votes
1
answer
3k
views
Drawing boundaries on a map with LeafletJS
I'm starting to play with code that can generate maps. I am now looking at OSM (OpenStreetMaps) as a great solution. Also LeafletJS makes it very easy to draw maps based on OSM. So far so good.
I ...
3
votes
1
answer
2k
views
Offline map without a tile server
Tell me, please, I need to create an application that without the Internet will load an (offline) map of some area and it will be possible to indicate the path on it with points (points will be ...
0
votes
1
answer
262
views
Leaflet animated marker not displaying the latitude and longitude
I am using this code it shows the message in a popup when I remove the e.latlng.lat and + e.latlng.lng
var myMovingMarker = L.Marker.movingMarker([
[23.59582641820334, 58.439605236053474],
[21....