Problems using dhtmlxWindow together with openLayers

I am in the process of developing a page that displays a map using openLayers and uses dhtmlxWindows to display additional information. While these are both great frameworks and I have got them to work independently I am having a display issue when combining them.



In IE7 everything works great. However in IE8 native mode, Firefox 3 and Safari 4 I experience the same problem that when the window opens as a modal window it is still behind the map image.



I have posted a simple example @ cmainfo.co.za/test/index.htm to demonstrate this problem.


Hello,


Try to set the following class for the openLayers (just place it into the style tag on the page this components):


div#olMap_OpenLayers_ViewPort { z-index: 1; }


Possibly it’ll fix the issue.


Thank you Alex for your prompt reply and pointing me in the right direction.



Doing some debuging I see that the map’s ViewPort div has a z-index of 0 in IE7 and is blank in the more compliant browsers. I  am working in ASP.NET and the name of the map’s div gets changed so I have come up with the following solution which is working in all the browsers I have to test on.   After calling the map constructor I then use the following code to set the z-index of the ViewPort:



map = ……;
$get(map.div.id + “_OpenLayers_ViewPort”).style.zIndex = 0;



This works equally well with a value of 0 or 1. Seems the problem was no value being set.