Actions

Widget

Difference between revisions of "Markers"

From Dragon Eye Atlas

Line 24: Line 24:
       var popup = new mapboxgl.Popup({ offset: [0, -15] })
       var popup = new mapboxgl.Popup({ offset: [0, -15] })
         .setLngLat(feature.geometry.coordinates)
         .setLngLat(feature.geometry.coordinates)
         .setHTML('<a href="https://notveryprofessional.com/dragoneye/atlas/'+feature.properties.name+'">'+feature.properties.name+'</a><br />('+features.properties.type+')')
         .setHTML('<a href="https://notveryprofessional.com/dragoneye/atlas/'+feature.properties.name+'">'+feature.properties.name+'</a><br />('+feature.properties.type+')')
         .addTo(map);
         .addTo(map);
   });
   });

Revision as of 01:12, 6 October 2019

Enable Clickable Markers

Parameters

  • layer - which layer to activate markers for. That layer must have "name" and "type" properties