Back To Start Of Archive
Taken From The Forum: Archived Topics for the old Version 3.0 JavaScript Menu
Forum Topic: Click to view post
Last Updated: Wednesday July 18 2012 - 06:07:45
Can't use in frames with external content
Poster: webmaster __at__ bryansbunch.com
Dated: Thursday February 21 2002 - 17:46:04 GMT
Using a nav frame and a main content frame.
Any time you load a page in the content frame that doesn't "onload" the script, you get the "Object doesn't support this property of method" script error when you mouseover the menu. (IE 6)
If only the top level menu (called from the nav frame) could be persistent without worrying about whether or not the submenus were loaded (ought to trap this error gracefuly anyway - pointing out there's a problem with the submenu object(s) instead of crashing), then I could place a "Home" button in the first position of the top level menu that could bring the user back to my local pages where the body contains the script loader and the submenus resume functionality.
Re: Can't use in frames with external content
Poster: Seth
Dated: Friday April 5 2002 - 8:44:08 BST
I noticed this problem as well. If/when you come up with a solution, let me know?
Re: Can't use in frames with external content
Poster: chris __at__ blue-canoe.net
Dated: Friday April 5 2002 - 11:05:16 BST
Change this in mmenus.js:
function popi(v1,lyr,el)
... some code ...
else if(frt>0)
{
lt=parseLink(v1, "target");
if(lt)
{
v1=v1.substring(10,frt);
close_el(v1)
pf=parent[lt];
if(pf)pf.closeallmenus();
}
}
... some code ...
to read [see the try{}catch(error){} block]:
else if(frt>0)
{
lt=parseLink(v1, "target");
if(lt)
{
v1=v1.substring(10,frt);
close_el(v1)
pf=parent[lt];
if(pf){
try{pf.closeallmenus();}
catch(error){}
}
}
}
I believe that this is caused by mistakenly trying to call a function in the parent window of the called frame that doesn't exist?
I will look further into it.
Chris Barber.
correct me if i am wrong...
Poster: gstadter
Dated: Saturday May 25 2002 - 17:50:47 BST
i made this modification, but still got errors "expected }" until i additionally added another }, immediately after the "catch(error){}" in your fix.