CSS how to target background and make it transparent
I am using IE6 and the only occupicy thing i can thing that works is opacity: 0.5; filter: alpha(opacity = 50);
background-color:black;
opacity: 0.5;
filter: alpha(opacity = 50);
this works but it makes the text transparen开发者_开发问答t as well how can I make only the background colour transparent
it's simple only you have do is to give
background: rgba(0,0,0,0.5)
& for IE use this filter
{background: transparent;-ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr=#7F000000,endColorstr=#7F000000)"; /* IE8 */ filter: progid:DXImageTransform.Microsoft.gradient(startColorstr=#7F000000,endColorstr=#7F000000); /* IE6 & 7 */ zoom: 1;}
for more about color transparency in IE you have to read about hsla color: http://greenevillage.net/csspages/hsla.aspx
You need to have a look at this trick here:
http://randaclay.com/tips-tools/how-to-make-your-backgrounds-transparent-using-css/
精彩评论