On May 24, 2010, at 3:26 PM, Christopher Schmitt wrote:

> 
> On May 24, 2010, at 2:39 PM, Eric A. Meyer wrote:
> 
>> At 3:34 PM -0400 5/24/10, Matthew wrote:
>> 
>>> I am wrestling with setting the opacity on background colors on a 
>>> div to expose a pattern behind it. However I can't figure out how to 
>>> keep the elements contained with in it at 100% opacity. Please see 
>>> this page to see what I mean:
>>> 
>>> http://em-w.com/portPages/port_homeandhearth1.html
>>> 
>>> I would like the main image and the text to remain a solid color, 
>>> while the white background has a 50% opacity level.
>> 
>>  div {background-color: rgba(255,255,255,0.5);
>> 
>> That won't work in IE/Win, I believe, but it will in pretty much 
>> anything else of recent vintage.  Alternatively, you could create a 
>> smallish PNG which is all white and has 50% opacity and drop it into 
>> the background of the div.  That will work in all current browsers 
>> including IE/Win.
> 
> Also, you can use IE filter for gradients, which allow for opacity:
> 
> div { 
> filter:progid:DXImageTransform.Microsoft.gradient(startColorstr=#66FFFF00, 
> endColorstr=#66FFFF00 ); }

Should be #FFFF00 is the color and the first hexadecimal value is the color 
opacity.

Thanks to Claude for the reminder :)

> Best,
> Christopher Schmitt
> http://www.christopherschmitt.com/
> Web Design Specialist
> --
> Attend the online CSS3 + July 4 + HTML5 Presentation
> http://css3flag.eventbrite.com/
> Free on July 1, 2010
______________________________________________________________________
css-discuss [cs...@lists.css-discuss.org]
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