SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    SitePoint Member
    Join Date
    Mar 2003
    Location
    New York
    Posts
    2
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Question How do I make an image go over another image?

    Hi,Can someone tell me how to make an image go over another image,im not sure what its called.


    Like if I put a happy face smily and over that i put a sad face smily,is there a way to do that?

    I don't know where this should go....but help please.

  2. #2
    SitePoint Zealot
    Join Date
    Jul 2002
    Location
    Fort Lauderdale
    Posts
    123
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Do you mean the first image changes into the second one or the second should appear on top of the first?

    www.unpossiblemedia.com - A Fort Lauderdale based multimedia company.

  3. #3
    SitePoint Member
    Join Date
    Mar 2003
    Location
    New York
    Posts
    2
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Vasudevelopa
    Do you mean the first image changes into the second one or the second should appear on top of the first?


    I mean the second one should appear on top of the first.

  4. #4
    SitePoint Zealot
    Join Date
    Jul 2002
    Location
    Fort Lauderdale
    Posts
    123
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by moobgorrd
    I mean the second one should appear on top of the first.
    OK, put the second image in a layer and set its coordinates to be on top of the first one. Then use a function to toggle layer visibility.
    Code:
    function toggle() {
      vis = document.getElementById('img2').style.visibility;
      if (vis == "hidden")
        document.getElementById('img2').style.visibility = "visible";
      else
        document.getElementById('img2').style.visibility = "hidden";
    }
    Code:
    <a href="javascript:toggle();">
    
    <div id=img2 style="top:10px; left:20px;">
      <img src='./img2.gif'>
    </div>

    www.unpossiblemedia.com - A Fort Lauderdale based multimedia company.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •