...

View Full Version : Colored Transparent-ish Background?



keviokevio
07-18-2007, 07:50 AM
WHADDUP! I think this is my first post. anyway...

How would i get a colored semi-transparent background for a <div></div>? Like only SLIGHTLY transparent, a faded white if you're wondering, so that it supports the text but you can see the faint background image.

ttthhhhanks.

koyama
07-18-2007, 08:23 AM
How would i get a colored semi-transparent background for a <div></div>? Like only SLIGHTLY transparent, a faded white if you're wondering, so that it supports the text but you can see the faint background image.
Your best bet may be to use a semi-transparent PNG background image for that div. This works in major browsers except IE6.

In the future you may be using rgba-values (http://www.w3.org/TR/css3-color/#rgba-color) to set a background color with an alpha value as detailed in the CSS3 Color Module. Currently there is support for this in at least Safari 2 and Firefox 3 (alpha).

Blekk
07-18-2007, 12:20 PM
Shouldn't you be able to make a 1-pixel transulcent .png as the background-image and then just repeat it all over the div?

keviokevio
07-19-2007, 12:46 AM
ooooo alright... PNG i'll try that, cool.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum