WMS Legend Plugin for Leaflet
Posted by: Gavin Fleming | in Leaflet, QGIS | 10 years, 4 months ago | 0 comments

This weekend I was updating our map gallery at http://maps.kartoza.com and I wanted to have WMS legends in my maps. The maps are mostly generated using QGIS server which also produces a nice looking graphic for its getLegendGraphic requests. Since Leaflet does not seem have a legend control out of the box, I wrote a small leaflet plugin to do it.

In the future I may extend the control to automatically fetch getLegendGraphics from all loaded WMS layers, but for now it simply takes a complete legend graphic URI as parameter.

Leaflet is a great web mapping client and extending it with little plugins is very easy to do. If you want to use the plugin I wrote, head over to the plugin repository and give it a try!

Current rating: 3.5

Comments

There are currently no comments

New Comment

required

required (not published)

optional

required

Have a question? Get in touch!