Jump to content

[SOLVED] IE javascript and FireFOX


Mr_J

Recommended Posts

Hi all,

I`m no expert. Actually, I only used javascript sniplets for fun stuff like the date, pre-load images etc. Now, I have a PETS Site. I`m using the onmouseover function to display a small image when the user moves his mouse over the link, the image appear. This works except for 2 problems: IE reserves a block of the width and height of the image where FF only show the link. My second problem is: how to make the image disapeer after the user takes his mouse off the link, IF THIS CAN BE DONE...

This is my code:

<head>
<script type="text/javascript">
function mouseOver()
{
document.getElementById("b1").src="http://mrj.myjalbum.net/boston/slides/q.jpg"
}
function mouseOut()
{
document.getElementById("b1").src="#"  [color=blue]//I tried to use the img src as well [size=1]DON`t KNOW WHAT TO DO...[/size][/color]
}
</script>
<head>
<body>
<p>We are proud of our male sire <a href="http://mrj.myjalbum.net/boston/slides/q.jpg" target="_blank" onmouseover="mouseOver()" onmouseout="mouseOut()">
<img border="0" width="200" height="150" alt="Quen Bertasso" title="Quen Bertasso" id="b1"></a>, one of the best breeding blood lines in South Africa, but he will join Angel in retirement.</p>

 

Thank you in advance

Jaco

 

 

 

Link to comment
https://forums.phpfreaks.com/topic/155480-solved-ie-javascript-and-firefox/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.