CSS div opacity仅在外部div上

Joh*_*ith 4 html css styles opacity

我有两个div,外部和内部div.我有一个背景图像,外部div有一个不透明度设置,但我似乎无法让内部div不继承外部div的不透明度.我希望内部div是纯色.

我的代码在下面,这里有一个jsfiddle:http://jsfiddle.net/3TK3U/

<style type="text/css">

body
{
background-image:url('http://media-bubble.info/images/layout/background.png');
}

.outsideBox {
    width:70%;
    height:200px;
    background-color: #ffffff;
    opacity:0.7; 
    filter:alpha(opacity=70);
    text-align:center;
}

.insideBox {
    width:40%;
    height:80px;
    background-color: #999;
    z-index:999999;
}

</style>


<div id="Introduction" class="outsideBox">
    <div id="Introduction" class="insideBox">This is the inside box which should not inherit transparancy</div>
</div>
Run Code Online (Sandbox Code Playgroud)

kyl*_*ide 22

尝试使用 background-color: rgba(255,255,255,0.7); 没有不透明度或过滤器,使背景透明但不影响元素的内容.