-
Hover link on Image MouseOver
Hi,
I have a link and an image next to each other. I want to make the link hovered when I do mouseover on image. How do I do that ?
Here is the code I have now.
<a href="javascript:undefined" id="imageLinkId">GMNA</a>
<script language="javascript">
if( ... ) {
document.write('<img src="/graphics/channel/plus.png" id="div18Img" alt="Maximize this section" onMouseOver= >'); }
else {
document.write('<img src="/graphics/channel/minus.png" id="div18Img" alt="Minimize this section" onMouseOver= >'); }
</script>
Thanks
-
-
<a href="[address]">[linktext]<img src="[image]"></a>
Than program your CSS to do a hover on A
Ryan
Sevierville, TN
-
-
Thanks. The following Code worked for me.
<span class="imageLink"><a href="index.html">GMNA<script language="javascript">
if( ... ) {
document.write('<img src="/graphics/channel/plus.png" id="div18Img" alt="Maximize this section" onMouseOver= >'); }
else {
document.write('<img src="/graphics/channel/minus.png" id="div18Img" alt="Minimize this section" onMouseOver= >'); }
</script></a></span>
and in the CSS file
a img{border:none}
.imageLink a { position:relative; }
.imageLink a:hover { position:relative; text-decoration:underline }
.imageLink a img{position:relative; right:-5px;}
-
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
Bookmarks