[OpenLayers-Users] layer switcher problem..

MeLv1n wAuRaN melvinnesta at gmail.com
Sun Apr 12 20:18:51 EDT 2009


it works. Ok thanks

On Mon, Apr 13, 2009 at 7:10 AM, Alexander Petkov <greenkov at gmail.com>wrote:

> On Sun, Apr 12, 2009 at 4:03 PM, MeLv1n wAuRaN <melvinnesta at gmail.com>
> wrote:
> >
> > Hi alexander,
> >
> > thanks for the quick reply. actually not all my layers but only some of
> my
> > layers. i tried including the visibility but it didn't work. maybe you
> can
> > check my codes:
> >
> > layer_jalan = new OpenLayers.Layer.WMS( "Jalan",
> >
> > "http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/Skripsi/coba.map
> ",
> >              {layers: 'jalan',
> >              transparent: "true", format: "image/png"},
> >              {singleTile: true},
> >              {visibility: false});
> >
> Try this:
>
>  layer_jalan = new OpenLayers.Layer.WMS( "Jalan",
>  "http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/Skripsi/coba.map",
>              {layers: 'jalan',
>              transparent: "true", format: "image/png"},
>              {singleTile: true, visibility: false});
>
> 'singleTile' and 'visibility' go together in the options hashtable:
>
> http://dev.openlayers.org/releases/OpenLayers-2.7/doc/apidocs/files/OpenLayers/Layer/WMS-js.html#OpenLayers.Layer.WMS.OpenLayers.Layer.WMS
>
> Alex
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-users/attachments/20090413/c1a3ef09/attachment.html


More information about the Users mailing list