SitePoint Sponsor |
|
User Tag List
Results 1 to 5 of 5
-
Nov 27, 2008, 10:57 #1
- Join Date
- Nov 2008
- Posts
- 3
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
i require a source for when i hover over an image it changes to another image!!
hi im trying to design a web page for my uni project in this web page i have thumbnail imges what i would like to achieve is that when i hover over an image with my mouse another image appears an over rights the previous image. if i was to go over the imge again then the image would change to nother image and over write the previous image and if i was to go over the image again then the image would go back to the first image. so its like images layerd behind each other. would ene1 knw how to do this thnx mathew.
-
Nov 27, 2008, 11:10 #2
- Join Date
- Jun 2003
- Location
- East Coast
- Posts
- 2,215
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
You want to use what is called a rollover.
http://www.google.com/search?hl=en&q...earch&aq=f&oq=
The basics would be this:
Code:<img src="image1.gif" onMouseOver="this.src='image2.gif'" onMouseOut="this.src='image1.gif'" />
█ Nick . all that we see or seem, is but a dream within a dream
█ Show someone you care, send them a virtual flower.
█ Good deals on men's watches
-
Nov 27, 2008, 12:10 #3
- Join Date
- Nov 2008
- Posts
- 3
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
hi thnx 4 dis. the images do rollover but then the third image rolls over when i move my mouse of the second image what i would like is dat the second image stays when i move my mouse of it and then when i put my mouse over the image again then it changes to the third image. i think i have to use the return false code but i dnt knw wher i would add it in my source. fnx mathew
-
Nov 27, 2008, 12:27 #4
- Join Date
- Jun 2003
- Location
- East Coast
- Posts
- 2,215
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
To clarify - when you rollover imageX the first time, it changes to imageY, and stays that way even when you roll off? And then when you rollover it the next time, it changes to imageZ, and stays on imageZ even when you roll of? Is this correct?
█ Nick . all that we see or seem, is but a dream within a dream
█ Show someone you care, send them a virtual flower.
█ Good deals on men's watches
-
Nov 27, 2008, 12:30 #5
- Join Date
- Nov 2008
- Posts
- 3
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
yes this is correct nd if i was to rollover imageZ it would go bak to imageX and keep going in that circle (LOOP). thnx
Last edited by mathew_1989; Nov 27, 2008 at 15:01.
Bookmarks