On Mon, Nov 22, 2010 at 8:35 AM, Jan Tappenbeck <[email protected]> wrote:
>
>
> hi !
>
> did anybody know if it is possible to show a layer only for special layers
> ??
>
> example zoom 9 to 12 ???
>
Use the map.zoom property to detect the zoom level and then turn off
(or on) the layers you want. Pseudocode ahead
if ((map.zoom >= 9) && (map.zoom <= 12)) {
map.removeLayer(layers[index]);
}
> regards Jan :-)
>
> _______________________________________________
> Users mailing list
> [email protected]
> http://lists.osgeo.org/mailman/listinfo/openlayers-users
>
--
Puneet Kishor http://www.punkish.org
Carbon Model http://carbonmodel.org
Charter Member, Open Source Geospatial Foundation http://www.osgeo.org
Science Commons Fellow, http://sciencecommons.org/about/whoweare/kishor
Nelson Institute, UW-Madison http://www.nelson.wisc.edu
-----------------------------------------------------------------------
Assertions are politics; backing up assertions with evidence is science
=======================================================================
_______________________________________________
Users mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/openlayers-users