我有一些需要自定义的代码
我的HTML
<div class="text-rotator add-top-half add-bottom-half align-left white-txt medium-txt uppercase highlight-bg">
<div class="rotator-wrap" style="display: block;">
<span class="rotate">Creating designs!</span>
</div>
</div>
我的CSS是:
.text-rotator {
line-height: 80px!important;
display: inline!important;
}
.text-rotator span {
background: #3399ff!important;
filter: alpha(opacity=60);
-moz-opacity: 0.6;
opacity: 0.6;
}
但是目前它正在设置文本和背景的不透明度,我无法弄清楚如何保留文本并仅更改背景。
有任何想法吗?
使用以下CSS:
.text-rotator span {
background-color:rgba(255,0,0,0.3);/*background color and opacity together*/
}
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句