Having problems with DHTML Menu? There is usually somebody here who knows the answer.
IndigoTide
Beginner
Posts: 5 Joined: Fri Aug 22, 2003 2:58 pm
Post
by IndigoTide » Fri Aug 22, 2003 3:13 pm
I am trying to set up a menu with all items being linked to html pages and several levels of sub menus. The top level is fine but the 2nd-level sub menu items with 3rd-level sub menus are showing up with a white background color instead of the tan I was using at this level. The mouse over color is not working either.
The second level style has all the same attributes as the top style.
Please let me know what I’m doing wrong.
Just found one more clue on the second level I am using :
subimage="images/arrow.gif";
subimagepadding="2";
When I remove these it works OK?
Last edited by
IndigoTide on Fri Aug 22, 2003 3:20 pm, edited 1 time in total.
Hergio
Milonic God
Posts: 1123 Joined: Wed Jun 12, 2002 7:46 pm
Location: Rochester, NY
Post
by Hergio » Fri Aug 22, 2003 3:20 pm
Tough to say without actually seeing it....got a URL? Sounds like your styles may be fishy.
Dave Hergert
Software Engineer
"Helping to make the menu better, one
at a time."
IndigoTide
Beginner
Posts: 5 Joined: Fri Aug 22, 2003 2:58 pm
Post
by IndigoTide » Fri Aug 22, 2003 3:23 pm
The page is not available to the extranet yet. So here is the code:
effect="fade(duration=0.3);Shadow(color='#373535', Direction=135, Strength=4)";
_menuCloseDelay=500;
_menuOpenDelay=150;
_scrollAmount=3;
_scrollDelay=20;
_followSpeed=5;
_followRate=40;
_subOffsetTop=0;
_subOffsetLeft=0;
with(MainMenuStyle=new mm_style()){
onbgcolor="#e9e9bb";
oncolor="#373535";
offbgcolor="#a47d56";
offcolor="#ffffff";
bordercolor="#a47d56";
borderstyle="solid";
borderwidth=1;
fontsize=11;
fontstyle="normal";
fontweight="bold";
fontfamily="verdana,arial,helvetica";
padding=6;
seperatorcolor="red";
seperatorsize=5;
seperatorpadding=5;
}
with(SubMenuStyle=new mm_style()){
onbgcolor="#e9e9bb";
oncolor="#373535";
offbgcolor="#cfcfa2";
offcolor="#373535";
bordercolor="#ffffff";
borderstyle="solid";
borderwidth=1;
fontsize=10;
fontstyle="normal";
fontweight="normal";
fontfamily="verdana,arial,helvetica";
padding=5;
separatorcolor="#ffffff";
separatorsize=1;
overfilter=effect;
subimage="images/arrow.gif";
subimagepadding="2";
}
// sample with menu images
// aI("showmenu=Links;image=images/links.gif;overimage=images/links_over.gif;");
with(milonic=new menuname("MainMenu")){
top=96;
left=7;
style=MainMenuStyle;
alwaysvisible=1;
alignment="left";
orientation="horizontal";
aI("text=About Amware;url=About.asp;showmenu=AboutMenu;status=Find out more about Amware corporation");
aI("text=Services;showmenu=ServiceMenu;");
aI("text=Facilities;showmenu=FacilityMenu;");
aI("text=FAQs;url=FAQs.asp;");
aI("text=Resources;showmenu=ResourceMenu;");
aI("text=Careers @ Amware;url=Careers.asp;");
}
with(milonic=new menuname("AboutMenu")){
style=SubMenuStyle;
aI("text=Management Bios;url=MgmtBios.asp;");
aI("text=Case Studies;url=Cases.asp;");
aI("text=Letter from President;url=Letter.asp;");
aI("text=Our Process;url=Process.asp;;separatorsize=1");
}
with(milonic=new menuname("ServiceMenu")){
style=SubMenuStyle;
aI("text=Warehousing;url=Warehouse.asp;");
aI("text=Transportation;url=Transport.asp;");
aI("text=Transload;url=Transload.asp;");
}
with(milonic=new menuname("FacilityMenu")){
style=SubMenuStyle;
aI("text=List of Facilities;url=FacList.asp;");
aI("text=Facility Overview;showmenu=FacOverMenu;url=FacOverview.asp;");
}
with(milonic=new menuname("FacOverMenu")){
style=SubMenuStyle;
aI("text=Map;url=Map.asp;");
aI("text=Management;url=FacMgmt.asp;");
aI("text=Contact Info;url=FacContact.asp;");
}
with(milonic=new menuname("ResourceMenu")){
style=SubMenuStyle;
aI("text=Links;url=Links.asp;");
aI("text=White Papers;url=WhitePapers.asp;");
aI("text=Newsletter;url=Newsletter.asp;");
aI("text=Press Releases;url=Press.asp;");
}
drawMenus();
IndigoTide
Beginner
Posts: 5 Joined: Fri Aug 22, 2003 2:58 pm
Post
by IndigoTide » Fri Aug 22, 2003 3:28 pm
I narrowed it down, it only happens when the Sub Images parms are there in the submenu style:
subimage="images/arrow.gif";
subimagepadding="2";
Hergio
Milonic God
Posts: 1123 Joined: Wed Jun 12, 2002 7:46 pm
Location: Rochester, NY
Post
by Hergio » Fri Aug 22, 2003 3:32 pm
subimagepadding="2";
should be subimagepadding=2;
try that, I think thats it. Make sure any place you reference JUST a number, no quotes, if there is letters, symbols, of any other type than a number, then use the quotes.
ADDITION: NICE CATCH ON THAT SPELLING JOHN!
Last edited by
Hergio on Fri Aug 22, 2003 4:37 pm, edited 1 time in total.
Dave Hergert
Software Engineer
"Helping to make the menu better, one
at a time."
IndigoTide
Beginner
Posts: 5 Joined: Fri Aug 22, 2003 2:58 pm
Post
by IndigoTide » Fri Aug 22, 2003 3:38 pm
Good Idea, but it did not make any difference. I even took the subpadding out and it still showed up with a white background.
John
Team
Posts: 5967 Joined: Sun May 19, 2002 8:23 pm
Location: Phoenix, AZ
Contact:
Post
by John » Fri Aug 22, 2003 4:20 pm
I see 3 problems right away (actually 1 problem 3 times). In your MainMenuStyle you have...
Code: Select all
seperatorcolor="red";
seperatorsize=5;
seperatorpadding=5;
A trip to the dictionary is in order here
Try sep
a rator. I suspect these parameters are being ignored entirely, and am not sure what else might happen.
John
IndigoTide
Beginner
Posts: 5 Joined: Fri Aug 22, 2003 2:58 pm
Post
by IndigoTide » Fri Aug 22, 2003 4:35 pm
That did it. It's amazing to me how things work when they are spelled correctly. This is one of my more frequent problems.
THANKS TO ALL,
Indigo
John
Team
Posts: 5967 Joined: Sun May 19, 2002 8:23 pm
Location: Phoenix, AZ
Contact:
Post
by John » Fri Aug 22, 2003 4:39 pm
Actually I usually have trouble with that same word (not to mention many others
). That's why I "cheat" and use good ol' copy/paste to get it right. This assumes, of course, we're c/p from 'separator', and not 'seperator'
John