Martin Friedrich
unread,Feb 14, 2013, 11:17:14 AM2/14/13Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to leafl...@googlegroups.com
Hi,
I have a map with markers in a MarkerClusterGroup. Depending on the Zoom Level I can see the Markers or one circle with the number of markers. This works fine.
Now I want to integrate the MarkerClusterGroup in my Layercontrol to make the Markers switchable. With the "standalone" markers this seems to be no problem. I can switch the Layer "aufgaben" on and off. But I also want to sitch the MarkerClusterGroup ( the circle with the number of markers). I tried to switch "cluster", but this doesn't work.
var cluster = new L.MarkerClusterGroup();
aufgaben.addData(csv);
cluster.addLayer(aufgaben);
map.addLayer(cluster);
var layersControl = new L.Control.Layers({
'Übersicht': cloudmade
}, {
'Aufgabe': aufgaben
});
I would be happy for ideas.
Regards
Martin