2014-05-08 262 views
0

我想使背景透明的白色,使得在背景半重疊圖像應該與白色:如何使白色透明背景?

這裏是我的代碼,但對我來說

background1 { 
    opacity:0.8; 
    filter:alpha(opacity=80); 
} 
+1

'background1'我猜這應該是'.background1'或'#background1'。這是一個開始。 – Ruddy

+1

try this..background1 {background:rgba(255,255,255,0.8);} – ilmk

+1

Mabye只是'background-color:rgba(255,255,255,0.5);' – pzaenger

回答

-2

使用,這並不正常工作工作正常,我...

background1 { 
    background-color: rgba(0, 0, 0, 0); 
    background-image: none, linear-gradient(to top, rgba(255, 255, 255, 0.75) 0px, rgba(255, 255, 255, 0.8) 10px, rgba(255, 255, 255, 0.86) 20px, rgba(255, 255, 255, 0.9) 30px, rgba(255, 255, 255, 0.94) 40px, rgba(255, 255, 255, 0.98) 50px, rgba(255, 255, 255, 0.99) 60px, #FFFFFF 70px); 
    background-repeat: repeat; 
} 
+0

這對你有用嗎?請給我演示一下! –

0

試試這個

div{ 
    position:relative; 
    display:inline-block 
} 
span{ 
    background: rgba(255,255,255,0.60); 
    width:100%; 
    position:absolute; 
    bottom:5px; 
    color:red; 
    padding:5px 
} 

DEMO