Milonic provide full featured pull down web menus for some of the worlds largest companies
click here to see what it can do for you

Download Milonic DHTML Menu
Buy Milonic DHTML Menu

Back To Start Of Archive
Taken From The Forum: Help & Support for DHTML Menu Version 5+
Forum Topic: Click to view post
Last Updated: Saturday July 14 2012 - 06:07:44

menu and frames question


Poster: lpotter
Dated: Tuesday May 10 2005 - 15:58:00 BST

I tried to search the forums, and could not find a clear answer.

I have a vertical menu setup in the left frame of a two frame layout. The menu will not open up into the right frame, making it useless in the frame. Can this be configured to cross the frame boundry?

The menu is large and deep and takes a while to load. So I'm playing with frames so the menu gets loaded only once, not with every page change.


Poster: kevin3442
Dated: Tuesday May 10 2005 - 17:19:55 BST

Hi,

There is a solution. Essentially, you have a main menu in the navigation frame, but the submenus are displayed in the main frame. You can see a more detailed explanation of the approach and a working example, complete with downloadable source code, here.

Hope that helps,

Kevin


Poster: lpotter
Dated: Tuesday May 10 2005 - 18:15:53 BST

thanks - looks like it should work, but most of my menu content lies in the submenus and they will be loaded in each page, meaning the menu data still has to load on every page load, so I don't think this solution will help me speed loading the page as I was trying to accomplish


Poster: kevin3442
Dated: Tuesday May 10 2005 - 18:24:35 BST

Is your menu_data in a .js file, or are you generating it wil server-side scripting? If it's just a plain ol' .js file, then it should be cached the first time the menu code is loaded, and loaded from the browser's cache (locally) each subsequent time. So, loading the menu code should not be taking a long time. Perhaps there's something else going on?

There's no other cross-frame solution. In a framed site, the content that can be displayed in a frame is limited to the content that is defined in the source file that's loaded into that frame. Menu or otherwise, no displayable content can straddle two frames.

Have you though about using the treemenu option? Since you have a vertical nav frame, you could load all of the menu code into the nav frame, and use a tree menu or collapsible menu, rather than a pop-out menu structure.

Cheers,

Kevin


Poster: Ruth
Dated: Tuesday May 10 2005 - 18:24:44 BST

I may be misunderstanding or be a bit confused here, but I think once the data file is read, it's in the cache and so it's not like it's getting a whole new file on each page, and having to 'read' and download the file again, it's already there. Or am I misunderstanding something here?

Ruth


Poster: kevin3442
Dated: Tuesday May 10 2005 - 18:53:49 BST

Hah! I did it to you that time Ruth! ;)

Check the time stamps... wow!

Kevin


Poster: lpotter
Dated: Thursday May 12 2005 - 2:12:55 BST

I don't think it's caching....

I removed the menu file includes from one of the content frame html pages. That page loads in a flash and the other pages that do load into the content frame menus are very slow.

So I think it does not cache the javascript files. at least it looks that way to me... and it's slow in both IE and Firefox.

The submenu javascript files are 220k in size.


Poster: Ruth
Dated: Thursday May 12 2005 - 3:21:56 BST

Could we please have a url? It's hard to try and figure what the problem is if we can't get to the page where the problem is occurring. Thanks

Ruth


Poster: lpotter
Dated: Thursday May 12 2005 - 16:03:14 BST

Can I send you a private message with the url for my menu page? It's not a public page.

It's just a webpage of my music collection for my private use, so I can remember what I own. The top level is A-Z and this menu is loaded in the left side frame. There are 26 choices in the top level menu.

The next level is the artists for each letter and then below that is the individual albums. There is a total of 400 artists and below the artists is a total of 1600 albums. There are lots of menu definations... The menu js files are written from a C++ program I wrote to write the web page for me using data exported from my music jukebox program.

The pages take a long time to load even when loading from my local machine. Prior to this I was using a frame based tree menu and this was very fast to load, since the tree only loaded once in it's frame.

Now I think the Artist and Album menu's are loading on each page load.