4

I have a OpenLayers web map with LayerSwitcher control added. I need this to switch some of my layers. But I am also adding and removing some layers, which are temporary and I do not want them added to the LayerSwitcher Control.

So is there a way to add layer to OpenLayers, but without it getting automatically added in LayerSwitcher Control?

1 Answer 1

10

Simple, just set displayInLayerSwitcher: false in the layer options.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.