I have a sass mixin that allows me to define alpha backgrounds
@mixin background-rgba($r,$g,$b,$a) {
$color: ie_hex($r,$g,$b,$a);
$value: unquote("progid:DXImageTransform.Microsoft.gradient(GradientType=0,startColorstr=##{$color},endColorstr=##{$color})");
//ie
-ms-filter: $value;
filter: $value;
zoom: 1;
background-color: transparent\9;
// Good browsers.
background-color: rgba($r,$g,$b,$a);
This works for IE 7-8, but the filter rule is being picked up by IE9. I realize I can use conditional tags in the <head>
but that isn't really what I need. I need to be able to use this all over the place.