tags:

views:

51

answers:

2

I want one image above the other. How can I do it?

http://twitpic.com/2cnpku

+1  A: 

Set the image you want on top to have a higher z-index. Right now, it has a lower z-index.

Robusto
the problem is the images are not showing but everything is right name and address
SDK_User
+2  A: 

from the code you posted, it appears you are passing an img element into another the src attribute of another img element. Is there a reason you are doing this?

<style type="text/css">
  .imgA1 {position:absolute;
          top:0px;
          left:0px;
          z-index:2;
          width:1300px;
          height:283px;}
  .imgB1 {position:absolute;
          top:0px;
          left:0px;
          z-index:1;
          width:1300px;
          height:1000px;}
</style>
<img class="imgA1" src="images/home_nav.png" alt="home_nav" />
<img class="imgB1" src="images/paperbackground.png" alt="Background" />

A similar code mockup can be seen at http://jsfiddle.net/gBPBd/3/ with my images to prove the concept and it is funcitoning in chrome, ie8.

Gabriel
Thanks Gabriel But The Home Nav image is still behind the paper background image. @Gabriel
SDK_User
<style type="text/css"> // if imgA1 is intended to be on top set a higher z-index .imgA1 {position:absolute; top:0px; left:0px; z-index:3; width:1300px, height:283px;} .imgB1 {position:absolute; top:0px; left:0px; z-index:1; width:1300px, height:1000px;}</style>----------------------------------.imga1 is staying behind??
SDK_User
I worked on it a bit more, looks like my comment was breaking the selector. I have modified it. You can also see it working here http://jsfiddle.net/gBPBd/3/ though I have used my own images so you can see the result.
Gabriel
Working Now Thanks Everybody!
SDK_User
please mark as answer.
Gabriel