• 0

[CSS] Image Hover Effect


Question

Hi! I'm having a minor "issue" if you can call it that with a new website that I designed. I'm using a CSS drop down menu and an image hover effect simultaneously. My issue is that I can't get the image mouseover effect to stay on while browsing the drop down menu.

Here's the link to the website:

http://www.amsautowerks.com/services.php

Here is my code, in a nutshell.

<li><a href="../services.php" class="dir" onMouseOver = "rollover('services')" onMouseOut  = "rollout('services')"><img src="../img/services.png" name="services"></a>
<script type="text/javascript">
<!--
setrollover("../img/services_on.png");
//-->
</script>
		<ul>
			<li><a href="../services.php?rev=ams/autobody">Autobody</a></li>
			<li><a href="../services.php?rev=ams/welding">Aluminum & Steel Welding</a></li>
			<li><a href="../services.php?rev=ams/repair">Repair Work</a></li>
			<li><a href="../services.php?rev=ams/software">Software Tuning</a></li>
			<li><a href="../services.php?rev=ams/turbokits">Turbo Kit Fabrication</a></li>
		</ul>
	</li>

Thanks!

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

  • 0
try moving the onmouseover and onmouseout to the parent li. or better yet ditch the javascript and do it in css.

Duh! I'm such an idiot. Thanks man! Works perfect :)

Link to comment
Share on other sites

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.