thickbox overlay incorrect in ie6/7
-
14-04-2021 - |
Domanda
hello i am using thickbox with jquery. however in ie6/7 with the standard css that comes with thickbox it works ok with ie8 and ff but not ie7. i have tried a hack but that dosent work. (posted below). what happens is that if i use the hack it dosne't affect the transparent overlay at all. if i do not use the hack it only shows 50% of the page transparent. can someone show me where to troubleshoot this? many thanks
#TB_overlay {
position: fixed;
z-index:100;
top: 0px;
left: 0px;
height:100%;
width:100%;
}
#TB_overlay { position: absolute; z-index:100; top: 0px; left: 0px; background-color: #000000; filter:alpha(opacity=85); -moz-opacity: 0.7; opacity: 0.75; min-height:100%; height: auto; _height:100%; /* pour IE 6 */ height : 1px; } /* pour les autres navigateurs */
* > #TB_overlay { height: auto; } /* pour IE 7 */
*+html #TB_overlay { min-height : 1px; }
Soluzione
Try something like this (modified from fancybox's css):
#TB_overlay {
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background-color: #000;
z-index: 100;
filter:alpha(opacity=85);
-moz-opacity: 0.7;
opacity: 0.75;
}
* html #TB_overlay {
position: absolute;
height: expression(document.body.scrollHeight > document.body.offsetHeight ? document.body.scrollHeight : document.body.offsetHeight + 'px');
}
Altri suggerimenti
Same problem in Firefox but it works if:
width: 100% !important;
height: 100% !important;
cheers
Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow