[OpenLayers-Users] Problem with maxZoomLevel, WFS land Google layers

Evaldas Taroza e.taroza at gmail.com
Wed Jan 31 05:33:55 EST 2007


I tried to specify numZoomLevels:17 for all the layers, including Markers,
however, when I zoom to that point, markers still disappear (The Markers
layer in the layer chooser is greyed).

How do I overcome that?

I am using version 2.3-rc2

Zeppe

On 1/19/07, Pedrazzi Gelsomini <pedrazzi.gelsomini at gmail.com> wrote:
>
> Hi everyone,
>
> I have a problem with the "maxZoomLevel" attribute.
> I need to have a maxZoomLevel bigger than 16 for my "Google Satellite"
> layer.
> So I tried to set the 'maxZoomLevel' at 17 (or more).
> The problem is that I can zoom-in the Google map layer until 17, but after
> 16 my markers disappear.
> I added my marker from mapserver like a WFS layer.
> What is the trouble?
>
> This is a piece of my code:
> ______________________________________________________________________________________________________________________
>
>
>         map = new OpenLayers.Map('map', {controls: [], 'numZoomLevels':17,
> unix:'meters', projection: 'EPSG:4326'});
>
>         var satellite = new OpenLayers.Layer.Google( "Google Satellite" ,
> {type: G_SATELLITE_MAP, 'maxZoomLevel':17} );
>         var hybrid = new OpenLayers.Layer.Google( "Google Hybrid" , {type:
> G_HYBRID_MAP, 'maxZoomLevel':17});
>         var normal = new OpenLayers.Layer.Google( "Google Map" , {type:
> G_NORMAL_MAP, 'maxZoomLevel':17});
>
>
>         var wfs = new OpenLayers.Layer.WFS( "Points WFS",
>                 "http://localhost/cgi-bin/mapserv?map=/var/www/mysite/mapserver/config/my_points.map&
> ",
>         {typename: "points", maxfeatures: 100, maxZoomLevel : 17,
> 'layers': 'points'},
>                 { featureClass: OpenLayers.Feature.WFS},
>         {isBaseLayer: false});
>
> ______________________________________________________________________________________________________________________
>
> I read a comment (http://openlayers.org/pipermail/users/2006-November/000108.html)
> about a similar problem, but with a WMS layer and not a WFS layer.
> The answer was:
>
> " This problem is probably related to the fact that numZoomLevels for the
> WMS layer is by default less than that for the Google layer, so you can zoom
> in farther for Google, and the WMS layer turns off.
> I'm not sure though, so if you can't figure out how to resolve it, it
> probably makes sense to open a ticket in Trac. "
>
> Do you think that it is the same problem that I have?
> Any suggestions?
>
> Thanks so much!
> Francesca
>
> _______________________________________________
> Users mailing list
> Users at openlayers.org
> http://openlayers.org/mailman/listinfo/users
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-users/attachments/20070131/fe3fa294/attachment.html


More information about the Users mailing list