jonathonoss
MIS
Hi,
I am attempting to use frames in a website, but run into problems with NN47 and NN60. I have images on one frame that, when clicked, will change the webpage in the other frame. Should be pretty simple, right?
Everything would be fine, but NN47 doesn't recognize ONCLICK methods within an image. Therefore the following code won't work on NN47 (but will on IE and NN6):
<img src="whatever.gif" onclick="return myjscode()" id="whatever" width="20" height="20">
So now I need to use <A HREF=""> tags around the image as such, because NN47 recognizes this:
<a href=javascript: onclick="return myjavascript()"><img src="whatever.gif" id="whatever" width="20" height="20"></a>
The JavaScript code that gets called is
function myjavascript()
{
window.parent.frameb.location.href = "mywebpage.htm"
return true;
}
My problem with this is that with NN47, the COMMUNICATOR CONSOLE always pops up! NN47 performs the JavaScript well, but I can't stop the COMMUNICATOR CONSOLE from appearing. I can only assume this is what will happen to all NN4x browsers.
My other problem is with NN6. The image with the onclick event running the JavaScript is in FrameA. FrameA disappears each time the onclick method is run, although it DOES update FrameB with the correct web page. If I put an 'alert(""' command before 'return true;', then FrameA does not disappear. This must be a bug with NN6, but surely people use type of code in their websites. I can not believe such simple code has so many problems.
Any ideas?
Thanks,
Jon
I am attempting to use frames in a website, but run into problems with NN47 and NN60. I have images on one frame that, when clicked, will change the webpage in the other frame. Should be pretty simple, right?
Everything would be fine, but NN47 doesn't recognize ONCLICK methods within an image. Therefore the following code won't work on NN47 (but will on IE and NN6):
<img src="whatever.gif" onclick="return myjscode()" id="whatever" width="20" height="20">
So now I need to use <A HREF=""> tags around the image as such, because NN47 recognizes this:
<a href=javascript: onclick="return myjavascript()"><img src="whatever.gif" id="whatever" width="20" height="20"></a>
The JavaScript code that gets called is
function myjavascript()
{
window.parent.frameb.location.href = "mywebpage.htm"
return true;
}
My problem with this is that with NN47, the COMMUNICATOR CONSOLE always pops up! NN47 performs the JavaScript well, but I can't stop the COMMUNICATOR CONSOLE from appearing. I can only assume this is what will happen to all NN4x browsers.
My other problem is with NN6. The image with the onclick event running the JavaScript is in FrameA. FrameA disappears each time the onclick method is run, although it DOES update FrameB with the correct web page. If I put an 'alert(""' command before 'return true;', then FrameA does not disappear. This must be a bug with NN6, but surely people use type of code in their websites. I can not believe such simple code has so many problems.
Any ideas?
Thanks,
Jon