We help IT Professionals succeed at work.

set background opacity without effecting text content

ellandrd
ellandrd asked
on
663 Views
Last Modified: 2008-03-17
i want to apply some opacity to a div background but keep the foreground the same - e.g textual content.  

i followed this example in: http://developer.mozilla.org/en/docs/CSS:-moz-opacity but everything gets effect - background and foreground.
Comment
Watch Question

Top Expert 2007
Commented:
This one is on us!
(Get your first solution completely free - no credit card required)
UNLOCK SOLUTION

Author

Commented:
you wont believe me but this was the site i was looking for.  i had it bookmarked but i couldnt find it.  i was hoping somebody would the site here or post another site like it...

before i opened this question, i tried to position the text over the div element and it wasnt working for me. but after scanning over the site above again,  i have to actually move the child element outside the parent element for it to work but i couldnt remember....  i was doing this:

<div><p></p></div>

cheers

ellandrd
Unlock the solution to this question.
Join our community and discover your potential

Experts Exchange is the only place where you can interact directly with leading experts in the technology field. Become a member today and access the collective knowledge of thousands of technology experts.

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.