Can't get menu from another page

Having problems with DHTML Menu? There is usually somebody here who knows the answer.
Post Reply
RBoone
Advanced
Advanced
Posts: 12
Joined: Sun Sep 07, 2003 6:51 am
Location: Fremont, CA USA
Contact:

Can't get menu from another page

Post by RBoone »

I have the menu files stored in a dedicated directory under the sites main directory. The menu is displayed on the index page just fine.

index is in directory bg
Menu is in directory bg/mmdata

Tried to insert the 2 script lines in a Help page that is stored in
bg/help - so modified the calls to milonic_src and the menu_data to read
../mmdata/milonic_src.js - etc. so that will call back up one and down to mmdata.

I get a script error 'object expected' or no error and no menu.
have played around with the calls, but cannot get it to display.
Shouldn't it display when called from the proper sub-directory?

in milonic_src the scriptpath is defined as ./mmdata
I had to do that with this menu setup, though testing with another setup did not require it.

Any suggestions? Thanks!
User avatar
Hergio
Milonic God
Milonic God
Posts: 1123
Joined: Wed Jun 12, 2002 7:46 pm
Location: Rochester, NY

Post by Hergio »

You are using version 5, so you are in the wrong forum. But I think we can solve your problem in a giffy.

Second, if you are allowed, try downloading the newest version of the menu. It includes some nice new docs and we have eliminated the scriptpath variable to simplify things alittle. If you cant I can help you with what you currently have.

Your reference to your menu in your pages should ALL say src="/bg/mmdate/milonic_src.js" or src="/bg/mmdata/menu_data.js", you get the picture. This will ensure every page can find the menu files since the beginning / means start from the root (starting after the com in blahblah.com). Your scriptpath should be scriptpath="/bg/mmdata/";

But again I advise upgrading to RC 10. But you may not be able to download just yet due to bandwidth concerns, we are currently meeting to determine what the next course of action will be.
Dave Hergert
Software Engineer
"Helping to make the menu better, one :?: at a time."
User avatar
John
 Team
 Team
Posts: 5967
Joined: Sun May 19, 2002 8:23 pm
Location: Phoenix, AZ
Contact:

Re: Can't get menu from another page

Post by John »

RBoone wrote:in milonic_src the scriptpath is defined as ./mmdata
The ./ is invalid anyway (unless you just finger-fumbled). However, given that small bit of info, that tells me you're not running the current version of v5. Therefore, right below the scriptpath are a bunch of notes from Andy that specifically say it must begin and end with a / . Use server-relative addressing as Dave outlined.
John
Post Reply