我试图使我的背景图像透明,但页面的其余部分不透明html背景图片透明度,例如非褪色和 CSS 之上的褪色背景图像。
我有一个 HTML 页面,使用 div 作为背景图像。 以下是该页面的简化版本:
#BACkgroundImage { BACkground-image: url('../Documents/images/Sea.jpg'); BACkground-repeat: no-repeat; BACkground-size: 100%; opacity: 0.4; filter:alpha(opacity=40); height:100%; width:100%; z-index:0.1; } .main{ height:500px; width:900px; margin:auto; BACkground-color:green; z-index:1; opacity: 1; filter:alpha(opacity=100); } <div id="BACkgroundImage">