Backgroundcolor in dtmlxWindows

Hi,



I’m using the pro version and have a problem with the background color using dhtmlXWindows. Here my code:







Using “dhxWins.window(“w1”).attachURL( url , false);” everything works fine, but the backgroundcolor of the window is allways white. Using “dhxWins.window(“w1”).attachURL( url , true);” the backgroundcolor is ok, but my defined stylesheet disappears.



What’s wrong? Can you help me?

Thanks.


Hello,


Where is the background colour defined ?


In case of attachURL(url,true) the page content is loaded by Ajax. It means that the content is part of the page. That is why the styles, that are defined on the main page, are applied.


If you use attachURL(url,false) or attachURL(url), the page is loaded into iframe inside a window. So, the background colour must be defined also in the page you load into the window.

I’m using dhtmlxwindows_modern_blue.css and in that stylesheet the background color of the created window is light grey. Loading a html-file into the the window with its own stylesheet I would like to get the background transparent in order to use the predefined dhtmlx-background color. Setting the background to transaparent the background color appears always white.


You can try to use the following approach:



div.dhtmlx_wins_body_content{
background-color: lightgrey !important;
}
div.dhtmlx_wins_body_content iframe{


/here you can set the necessary opacity/
filter:alpha(opacity=50);
-moz-opacity:0.5;
opacity:0.5;
}