[OpenLayers-Users] change of baselayer changes mapExtent

Sven Burbeck sburbeck at bfs.de
Mon Mar 28 06:31:06 EDT 2011


Hi,
first of all thanks to Andreas and Mathias and sorry for my late response!

The problem was indeed, that the two baselayers had different maxResolution.
Defining maxResolution for the "map" solved the problem (unfortunately
the layers had different maxResolutions for good reason....but that's a
different story :-) )

cheers,
Sven


Am 24.03.2011 13:40, schrieb Andreas Hocevar:
> Hi,
>
> make sure that all your base layers have the same maxExtent, maxResolution, projection and units, or set them as options on the map instance.
>
> Andreas.
>
> On Mar 24, 2011, at 11:52 , Sven Burbeck wrote:
>
>   
>> Hi list,
>> I have the following problem.
>> My baselayer is of type "OpenLayers.Layer.Google".  MapProjection =
>> "EPSG: 3857" (same as 900913).
>> So far everything works well.
>> Now I would like to add a second Baselayer of type
>> "OpenLayers.Layer.WMS".  (Fist I tried using this layer as overlay-layer
>> and everything worked well)
>> However, when adding it as baselayer and changing the baselayer by
>> radiobutton apparently the mapExtent changes and I can't display the new
>> baselayer (WMS) anymore.
>>
>> Is there anything, that I have to take into account when adding a layer
>> as baselayer rather than as overlay?
>>
>> cheers,
>> Sven
>>
>> -- 
>> Sven Burbeck
>> Bundesamt für Strahlenschutz (BfS)
>> SW 2.1
>> Rosastr. 9
>> D-79098 Freiburg
>> phone:	++49 (0)3018 333 6741
>> fax:	++49 (0)3018 10 333 6741
>>
>> _______________________________________________
>> Users mailing list
>> Users at lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/openlayers-users
>>     
>
>
>   

-- 
Sven Burbeck
Bundesamt für Strahlenschutz (BfS)
SW 2.1
Rosastr. 9
D-79098 Freiburg
phone:	++49 (0)3018 333 6741
fax:	++49 (0)3018 10 333 6741



More information about the Users mailing list