...

View Full Version : browser compatibility issue



Kal
01-02-2007, 10:11 AM
Hi,

i have the following function which changes an image in one frame as you hover over various links in the menu frame. Also if you click on the link or the image then the page will change in the main frame.

this works fine in Internet Explorer but not in Firefox the image doesn't change on hover over the link but everything else does, any help would be great.

could it be something to do with the way the frames are being referenced?

thanks in advance.

menu frame


<script language="JavaScript">

internet_main = window.parent.internet_main("internet_main.html","rollWindow","internet_main");

function getRolling(whichBrief,url){
internet_main.document.images.rollpic.src = whichBrief;
internet_main.document.images.rollpic.onclick=function(){
internet_main.document.location=url
}

}

</script>


<li><font color="#DB241C">Plan</font>

<ul>

<li><a href="/plan_1.html" TARGET="internet_main" onmouseover="getRolling('/plan_1.png','/plan_1.html')">> plan_1</a></li>

<li><a href="/plan_2.html" TARGET="internet_main" onmouseover="getRolling('/plan_2.png','/plan_2.html')">> plan_2 +</a></li>

<li><a href="/plan_3.html" TARGET="internet_main" onmouseover="getRolling('/plan_3.png','/plan_3.html')">> plan_3</a></li>

<li><a href="/plan_4.html" TARGET="internet_main" onmouseover="getRolling('/plan_4.png','/plan_4.html')">> plan_4</a></li>

</ul>

</li>


main frame


<div align="center">

<img src/internet_image_main.png" name="rollpic">

</div>

Arty Effem
01-02-2007, 02:25 PM
internet_main.document.images.rollpic.src = whichBrief;
internet_main.document.images.rollpic.onclick=function(){
internet_main.document.location=url
The other frame is addressed: parent.internet_main

Kal
01-02-2007, 02:36 PM
dont quiet understand, the line where it is addressed is all put in the variable internet_main anyway.

Kal
01-02-2007, 03:00 PM
All fixed now.

Arty Effem now understand, i just put parent. infront of those lines you quoted.

cheers



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum