[OpenLayers-Users] Map not visible when hidden div is unhidden

Zer zer_matt at hotmail.com
Thu Mar 4 05:11:51 EST 2010


Hi,

I have a map in a div within a table cell that is hidden (<td id=map
style=”display: none;”>) when the page loads. When the user clicks a button,
the table cell is unhidden by a java script. 

All the scripts that set up the map runs ok when the page is loaded and the
wfs-calls to Goeserver work fine. 

When the user clicks the button, and the map is visible, the base layers
(wms) and the wfs-layers are not visible. Instead there is a white tile in
the upper left corner. The zoom controls and layers switcher are visible. 
Is soon as the map is moved by just a few pixles, all the wms-tiles are
loaded from the server and the wfs-layer is shown. 

Is it by design, that the base layers will not load in a hidden element? If
so, does anyone have a solution to this problem? I really don’t want the
user to have to move the map in order to show the layers.


Thanks,

-ZM

-- 
View this message in context: http://n2.nabble.com/Map-not-visible-when-hidden-div-is-unhidden-tp4673385p4673385.html
Sent from the OpenLayers Users mailing list archive at Nabble.com.



More information about the Users mailing list