I have 6 different layers. Some are layers with markers and some other with raster data. In some point, when I zoom in the map, I create a vector layer. Upon adding the layer on the map I want a specific WMS layer to appear above the vector layer. That's why I do this:
map.setLayerIndex(wms_layer_network, map.layers.length+100); Although the layer indeed change position and comes to the top, on my map I don't see this change. The vector layer keeps being on top of the WMS. This is how I check the layer array and their position (assuming the last value of the array is the one which will appear on top):
var mLayers = map.layers; for(var a = 0; a < mLayers.length; a++ ){ alert(mLayers[a].name) }; Does anyone know why this happens?
أكثر...
map.setLayerIndex(wms_layer_network, map.layers.length+100); Although the layer indeed change position and comes to the top, on my map I don't see this change. The vector layer keeps being on top of the WMS. This is how I check the layer array and their position (assuming the last value of the array is the one which will appear on top):
var mLayers = map.layers; for(var a = 0; a < mLayers.length; a++ ){ alert(mLayers[a].name) }; Does anyone know why this happens?
أكثر...