- Impact
- 64
If you want to make a table that is semi-transparent, but with fully opaque contents (example here), use this code. I have tested it with opera 9, firefox 1.5 and ie 6.
Yep, you guessed it, all those non-standard tags are needed by IE (<comment> what kind of stupid idea is that...)
Code:
<style>
/*Transparency*/
#one {
position: relative;
}
#two {
z-index: 5;
position: relative;
}
#thr {
background-color: #FFFFFF;
border: 1px solid black;
opacity: 0.5;
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}
</style>
<comment><div id="one">
<div id="thr"></div>
<div id="two"></comment>
<!--[if IE]><table width="100%" cellspacing="0" cellpadding="10" border="0" align="center" style="filter: alpha (opacity=50);background-color:#FFFFFF;"><![endif]-->
<comment><table width="100%" cellspacing="0" cellpadding="10" border="0" align="center" style="background-color:#FFFFFF;"></comment>
<tr>
<td><!--[if IE]><div style="position:relative;"><![endif]-->
Content Goes Here
</td></tr></table>
<comment></div></div></comment>
Yep, you guessed it, all those non-standard tags are needed by IE (<comment> what kind of stupid idea is that...)







