Before asking this question, I saw a question: CSS background opacity with rgba, which doesn't work in IE 8 but doesn't work for me. I am creating a popup using only css. It works in ie9 + and mozilla25 + css, which I use for this: HTML:
<div id="backgroundFilter">
<div id="overBackgroundFilter"></div>
</div>
{
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background-color: rgba(184, 184, 184, 0.5);
}
{
position: static;
top: 0;
right: 0;
bottom: 0;
left: 0;
margin: auto;
height: 385px;
width: 400px;
background-color: #F8F8F8;
border-width: 6px;
border-color: #E0E0E0;
border-style: solid;
}
I change my css to ie8, it works for ie8, but it is not for mozilla. In mozilla, opacity is passed from backgroundFilter to overBackgroundFilter, I want only backgroundFilter to be transparent, and overBackgroundFilter not. Any ideas? Here css is changed for ie8:
#backgroundFilter
{
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: #B8B9BB;
-moz-opacity: 0.50;
opacity: 0.50;
filter: alpha(opacity =50);
}
#overBackgroundFilter
{
position: absolute;
display: block;
top: 0;
right: 0;
bottom: 0;
left: 0;
margin: auto;
height: 385px;
width: 400px;
background: #F8F8F8;
border-width: 6px;
border-color: #E0E0E0;
border-style: solid;
}
Thank!
source
share