I need help to display layers group/non group
1. with checkbox to select layer or group
2. icon/symbol for each layer.
I saw example codes from OpenLayers where it's adding the layers statically. I would like to populate it dynamically so in future if a layer is added/remove it will be displayed without changing any code.
Sample layout of what I want to achieve is posted below, please note that checkboxes are displayed as dots.
Groping of Layer
-
Layer
-
-
School
-
Road
-
-
Metal Road
-
Unmetal Road
-
-
Parecls
-
Water Feature
-
Cities
-
Disulict
-
India
-
Best Answer
I do this using JQuery, not the Openlayers Layer Selector
Basically:
Here is an example of the layer toggling functions (Make sure you declare the variable bathy with the right scope, ie: toy can access it from the onclick event on the check boxes)