- Oct 30, 1999
- 11,815
- 104
- 106
I've got two functions. First one loads and iFrame with content, the second is a simple image swap:
function over(imgname,imgsrc) {
document[imgname].src=imgsrc;
}
function loadIframe(iframeName, url) {
if ( window.frames[iframeName] ) {
window.frames[iframeName].location = url;
return false;
}
I want to pull off both functions with the same OnMouseOver event. Only works in NS though. Not IE. Something wrong with my syntax?
function MO1()
{
over('4600','2420mouseon.gif');
loadIframe('ifrm', 'Avaya2420.htm');
}
The link looks like this:
<a href="Avaya4600.htm" target="ifrm" onMouseOver="MO1();" onMouseOut="out('4600','images/2420mouseoff.gif');" >
<img src="images/2420mouseoff.gif" border=0 name="4600" width=600 height=30></a>
If I replace the "MO1()" with "over('4600','2420mouseon.gif')" or with "loadIframe('ifrm', 'Avaya2420.htm')" they both work in both browsers. I only have a problem running both together.
function over(imgname,imgsrc) {
document[imgname].src=imgsrc;
}
function loadIframe(iframeName, url) {
if ( window.frames[iframeName] ) {
window.frames[iframeName].location = url;
return false;
}
I want to pull off both functions with the same OnMouseOver event. Only works in NS though. Not IE. Something wrong with my syntax?
function MO1()
{
over('4600','2420mouseon.gif');
loadIframe('ifrm', 'Avaya2420.htm');
}
The link looks like this:
<a href="Avaya4600.htm" target="ifrm" onMouseOver="MO1();" onMouseOut="out('4600','images/2420mouseoff.gif');" >
<img src="images/2420mouseoff.gif" border=0 name="4600" width=600 height=30></a>
If I replace the "MO1()" with "over('4600','2420mouseon.gif')" or with "loadIframe('ifrm', 'Avaya2420.htm')" they both work in both browsers. I only have a problem running both together.