Plugin Contributor
hupe13
(@hupe13)
If you mean this plugin, there is Extensions for Leaflet Map. This plugin can group markers.
So can this extension allow a user to show only the markers of a group? For instance, only show french restaurants group on the maps instead of, all the groups?
Plugin Contributor
hupe13
(@hupe13)
Yes.
[leaflet-map fitbounds]
[leaflet-marker title="french" lat=... lng=... ]...[/leaflet-marker] //many markers
[leaflet-marker title="italian" lat=... lng=... ]...[/leaflet-marker] //many markers
[markerClusterGroup feat="title" strings="french,italian" groups="French Restaurants, Italian Restaurants"]
[zoomhomemap fit]
or you can distinguish with icons:
[leaflet-marker iconUrl="...french..." ... ] ... [/leaflet-marker]
[leaflet-marker iconUrl="...italian..." ... ] ... [/leaflet-marker]
//many markers
[markerClusterGroup feat="iconUrl" strings="french,italian" groups="French Restaurants, Italian Restaurants"]
[zoomhomemap fit]
These options are available so far. I may have another idea when I see your example.
You may have a number of say french restaurants dotted around a map, can you select from a side box to show just these? And similarly, options to select italian resteraunts etc?
If so, woudl the previous code work or would this be something different? (or is this somethign in development?)
Many thanks for your help so far.
Plugin Contributor
hupe13
(@hupe13)
You can use the code like above, these examples are adapted from the help page.
Hi, the selection box is all working well. One query, markers are colour coded, for instance french restaurant have a blue marker, italian a green marker. When more than one group is selected all the markers are clustered together and without the individual group colour coding.
Is it possible to cluster by group? Or when selecting a number of groups, to have a cluster for each group in that markers colour?
Hope that makes sense.
Plugin Contributor
hupe13
(@hupe13)
Is it possible to cluster by group? Or when selecting a number of groups, to have a cluster for each group in that markers colour?
I searched the Internet: It is possible in principle to have 2 markerClusterGroups and customize the marckerCluster style. But I have no idea and knowledge how to bring this together.