On 4/21/10 12:07 PM, Chris Blake wrote:
> Hi,
>
> http://s318194674.websitehome.co.uk/index.php?option=com_content&view=article&id=132&Itemid=1
> I was trying to apply a white, 50% opaque, background colour to a
> wrapper via CSS and see what happened! I have no idea CSS could do
> something like that!
>
[...]
>
> Here is the css (4 lines!):
> http://css-tricks.com/css-transparency-settings-for-all-broswers/
>

As already suggested, a semi-transparent PNG will work in most browsers, 
with the exception of IE before version 7. You can use a filter for that 
browser.

You can combine RGBA background-color with an image for older browsers, 
and a filter for IE 5/6 like this:

  div.wrapper-body {
     background: url(images/white-50pct-1px.png);
     background: rgba(255, 255, 255, .5);
  }
  /* IE 5-6 only */
  * html div.wrapper-body {
     background: transparent;
     filter: 
progid:DXImageTransform.Microsoft.gradient(startColorstr=#80ffffff,endColorstr=#80ffffff);
     height: 1%; /* give IE "layout" */
  }

Hope this helps.

Cordially,
David
--
______________________________________________________________________
css-discuss [[email protected]]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/

Reply via email to