469,348 Members | 1,261 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,348 developers. It's quick & easy.

Help with Mouseover and mouseoff please

Hi, I was wondering if there is a way to "unMouseOver"?

I have the following script that does the mouse over - but I want the image to go back to the original when the mouse leaves the area.

Expand|Select|Wrap|Line Numbers
  1.  
  2. <body>
  3. <script language="javascript"> 
  4. function ShowPic1(sImage) 
  5. {
  6.  sImage = "http://i157.photobucket.com/albums/t58/olivas_enterprises/" + sImage + ".jpg"; document.ShowRoom1.src = sImage; 
  7.  }
  8. function ShowPic2(sImage)
  9. {
  10.  sImage = "http://i157.photobucket.com/albums/t58/olivas_enterprises/" + sImage + ".jpg"; document.ShowRoom2.src = sImage; 
  11.  }
  12.  </script>
  13.  
  14.  
  15. <p dir="ltr">&nbsp;</p>
  16. <p dir="ltr" align="right">
  17.  <a onmouseover="ShowPic1('LSL')" href="http://i157.photobucket.com/albums/t58/olivas_enterprises/LSL.jpg" alt="Ship to Locations">
  18.  <img style="width: 128; height: 31" src="http://i157.photobucket.com/albums/t58/olivas_enterprises/DSL.jpg" name="ShowRoom1">
  19.  
  20.  <a onmouseover="ShowPic2('LCS')" href="http://i157.photobucket.com/albums/t58/olivas_enterprises/LCS.jpg" alt="Customer Service">
  21.  <img style="width: 128; height: 31" src="http://i157.photobucket.com/albums/t58/olivas_enterprises/DCS.jpg" name="ShowRoom2">
  22.  
  23.  
I tried to use the same code and changed onmouseover to onmouseoff - and that didnt' work.

Please help!
Thanks!
Sophie
Aug 10 '08 #1
2 1206
Nevermind - persistance has paid off - I found it! Thanks though.
Aug 10 '08 #2
acoder
16,027 Expert Mod 8TB
You obviously found onmouseout ;)

PS. code tags are of the square bracket type, i.e. [CODE], not <CODE>. Thanks!
Aug 11 '08 #3

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

1 post views Thread by new_sense | last post: by
3 posts views Thread by Annette Acquaire | last post: by
1 post views Thread by Oltmans | last post: by
1 post views Thread by CARIGAR | last post: by
reply views Thread by zhoujie | last post: by
1 post views Thread by Marylou17 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.