943,706 Members | Top Members by Rank

Ad:
Dec 19th, 2008
1

loading an image on hover over a link

Expand Post »
hi
i am new to java script and i am designing my web site but i want to load a new image on a particular place of my web page when a user hover over the home,contact us link
so pls tell how can i do this if you have the code then send to me
THANKU
-PC(INDIA)
Similar Threads
Reputation Points: 10
Solved Threads: 2
Light Poster
cpeeyush1 is offline Offline
29 posts
since Sep 2008
Dec 19th, 2008
0

Re: loading an image on hover over a link

I would use flash to do all this fancy effects.
Reputation Points: 10
Solved Threads: 1
Light Poster
dreamer14 is offline Offline
31 posts
since Sep 2008
Dec 19th, 2008
0

Re: loading an image on hover over a link

@cpeeyush1 - JSP stands for Java Server Pages not Java Script. Post moved!
Moderator
Featured Poster
Reputation Points: 2786
Solved Threads: 871
Code tags enforcer
peter_budo is offline Offline
6,655 posts
since Dec 2004
Dec 19th, 2008
0

Re: loading an image on hover over a link

Things can be done with CSS.
But here's a basic example to get you started...
JavaScript / DHTML / AJAX Syntax (Toggle Plain Text)
  1. <img src="yourImage.jpg" alt="[ Home ]" id="image1" onmouseover="this.src='home.jpg';" onmouseout="this.src='myImage.jpg';" /><br />
  2. <a href="#" onmouseover="document.getElementById('image1').src='home.jpg';" onmouseout="document.getElementById('image1').src='yourImage.jpg';">Hoover Me!</a>
Featured Poster
Reputation Points: 114
Solved Threads: 138
Posting Shark
essential is offline Offline
973 posts
since Aug 2008

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in JavaScript / DHTML / AJAX Forum Timeline: Play multiple wav files with embed element
Next Thread in JavaScript / DHTML / AJAX Forum Timeline: Javascript to make visible





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC