Image under background image

Hi there,

I have a div with a background image with parts of it transparent. Within that div, I have an image which I want to display behind the background image.

Is this possible?

Thanks!

It sounds like you have the images the wrong way around. The image that you want behind should be the background and the image with the alpha channel should go in the div on top.
If there is a very special reason why you need it this way around, there will be a workaround.

You can add the second image as another background image.

{background-image:url(one-image.jpg),url(another-image.jpg);}

http://www.w3.org/TR/css3-background/
https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Background_and_Borders/Using_CSS_multiple_backgrounds
http://www.w3schools.com/css/css3_backgrounds.asp

or search for “css3 background images”

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.