JavaScript Forum JS Made Easy: Free JavaScripts Tutorials Example Code
About This Product
The Business Internet
Find it on This page:
| Over 5000 Free Fonts | Tutorials | Javascript Forum | Other Javascript Resources | Cheat Sheet

Jsmadeeasy Forums Home   Search   Login   Register   Member List  
JS Made Easy  > JavaScript programming  > mouseover image change  
Display using:  
Previous Thread :: Next Thread 
 Author Thread: mouseover image change
jillus is not online. Last active: 2/20/2006 8:23:18 AM jillus
Joined: 19 Feb 2006
Total Posts: 1
mouseover image change
Posted: 19 Feb 2006 02:27 PM
im trying to use this code i found in the misc section... i would like it to work on all the links on my page, where when you hover over a link (image) a different one appears in its place. ive got it working but it seems only to work on one link and not all of them~ can you help??

(in HEAD)
<SCRIPT language="JavaScript">
<!-- Begin
function move_in(img_name,img_src) {document[img_name].src=img_src;}
function move_out(img_name,img_src) {document[img_name].src=img_src;}
// End -->
(in BODY)
<A HREF=/home.html onmouseover="move_in('button','/images/emoh.gif')"
<IMG NAME="button" SRC="/images/home.gif" border="0"></A>
<A HREF=/recordings.html onmouseover="move_in('button','/images/sgnidrocer.gif')"
<IMG NAME="button" SRC="/images/recordings.gif" border="0"></a>
<a class="menulinks" href=/gigguide.html><img src="/images/gigs.gif" border="0"></a>
<a class="menulinks" href=/band.html><img src="/images/band.gif" border="0"></a>
<a class="menulinks" href=/photos.html><img src="/images/photos.gif" border="0"></a>
<a class="menulinks" href=/fsguestbook.html><img src="/images/guestbook.gif" border="0"></a>
<a class="menulinks" href=/contact.html><img src="/images/contact.gif" border="0"></a></TD>

as you can see ive copied the code exactly- it works on the first link (home) but not on the second (recordings)...??
i don't understand :( is not online. Last active: 5/2/2006 11:43:02 PM
Top 50 Poster
Joined: 06 Nov 2005
Total Posts: 3
Re: mouseover image change
Posted: 30 Apr 2006 08:09 PM
Can you give direct link to check ? - Largest and greatest Javascript library in Vietnam
[] provide thousands of free JavaScripts, Example Code, DHTML, CSS, Resources and more
Previous Thread :: Next Thread 
Page 1 of 1  > JS Made Easy  > JavaScript programming  > mouseover image change