2 menus misbehaving

Having problems with DHTML Menu? There is usually somebody here who knows the answer.
Post Reply
dmj120
Advanced
Advanced
Posts: 17
Joined: Sat Jan 17, 2004 11:48 pm

2 menus misbehaving

Post by dmj120 »

I finally got two menus on one page. I am trying out CSS for the first time and it seems that the horizontal menu stays with the vertical menu.

thanks for any help
http://www.swlct.com/CSS_test_design1.htm is the page I'm having trouble with
User avatar
John
 Team
 Team
Posts: 5967
Joined: Sun May 19, 2002 8:23 pm
Location: Phoenix, AZ
Contact:

Post by John »

First off, note that you are way down-level. You're running RC28, and current is RC42. Upgrade!

Also, please add your license number to the comment near the top of the page.

In menu_data1.js you have removed...

Code: Select all

_menuCloseDelay=400           // The time delay for menus to remain visible on mouse out
_menuOpenDelay=150            // The time delay before menus open on mouse over
_followSpeed=5                // Follow scrolling speed
_followRate=50                // Follow scrolling Rate
_subOffsetTop=10              // Sub menu top offset
_subOffsetLeft=-10            // Sub menu left offset
_scrollAmount=3               // Only needed for Netscape 4.x
_scrollDelay=20               // Only needed for Netcsape 4.x
...from the code. It should be there.

Also, at the end you have...

Code: Select all

placeMenus();
It should be...

Code: Select all

drawMenus();
Try those for a start.
John
dmj120
Advanced
Advanced
Posts: 17
Joined: Sat Jan 17, 2004 11:48 pm

Post by dmj120 »

I did have

Code: Select all

_menuCloseDelay=400           // The time delay for menus to remain visible on mouse out 
_menuOpenDelay=150            // The time delay before menus open on mouse over 
_followSpeed=5                // Follow scrolling speed 
_followRate=50                // Follow scrolling Rate 
_subOffsetTop=10              // Sub menu top offset 
_subOffsetLeft=-10            // Sub menu left offset 
_scrollAmount=3               // Only needed for Netscape 4.x 
_scrollDelay=20               // Only needed for Netcsape 4.x
as well as the drawMenu

but it caused the vertical menu to disapear.

what's RC28 and how do I upgrade?

i could put the horizontal menu "menu_data1.js" at the bottom of the page without any problems, but at the top it just does what it wants to.
User avatar
Ruth
 Team
 Team
Posts: 8763
Joined: Thu May 15, 2003 5:02 am
Location: Yucaipa, CA
Contact:

Post by Ruth »

you get the new release candidates when you go to the main page, login and then click on the menu5 download version. There's an announcement at the top of this forum that lists whenever a new rc is available. As to the menu placement. You are putting the menu_data1.js one in a div and the other one in a table cell. First put the

Code: Select all

<SCRIPT language=JavaScript src="http://www.swlct.com/menu_data1.js" type=text/javascript></SCRIPT>
<SCRIPT language=JavaScript src="http://www.swlct.com/menu_data.js" 
type=text/javascript></SCRIPT>
back with the milonic_src.js and the other codes. Then take all the codes for the Main Menu1 and take it out of the menu_data1.js file and put it in the div like this

Code: Select all

<DIV id=topbottom>
<script>with(milonic=new menuname("Main Menu1")){
style=menuStyle12;
screenposition="center";
position="relative";
alwaysvisible=1;
orientation="horizontal";
aI("text=Home;url=http://www.e;");
aI("text=Southwest;showmenu=southwest1;");
aI("text=Nortwest;showmenu=Milonic1;");
aI("text=Cactus;showmenu=Partners1;");
aI("text=Ge Secure Links;showmenu=Links1;");
aI("text=another;showmenu=My Milonic1;");
}
drawMenus();
</SCRIPT>
</DIV>
Then take the codes for the Main Menu out of the menu_data.js file and put them in the table cell

Code: Select all

<TD height=100 vAlign=top><script>
      with(milonic=new menuname("Main Menu")){
style=menuStyle;
alwaysvisible=1;
position="relative";
overflow="scroll";
aI("text=Secure GE links;type=header;align=center;");
aI("text=CS Home Page;url=http://gemsweb1.med.ge.com/GEMS-CS/index.jsp;target=_blank;");
aI("text=Sourcing;url=http://gemsweb1.med.ge.com/GEMS-CS/portal/index.jsp?id=9;showmenu=Sourcing;target=_blank;");
aI("text=My Learning;url=http://med.home.ge.com/insideGE/jsp/learning/index.jsp;showmenu=Learning;target=_blank;");
aI("text=New Vendor;showmenu=Vendor;");
aI("text=Data Quality (NMM);url=http://gein.med.ge.com/csi/nmmindex.html;showmenu=Make;target=_blank;");
aI("text=Depot;url=http://gemsweb1.med.ge.com/GEMS-CS/portal/index.jsp?id=2;showmenu=Depot;target=_blank;");
aI("text=Human Resource;url=http://gemsweb1.med.ge.com/GEMS-CS/portal/index.jsp?id=4;showmenu=Hr;target=_blank;");
}
drawMenus();
</SCRIPT>
    </TD>
One other thing. You have that div id'd as topbottom with a background color of red, but that red won't show, the div is 100% and the menu spans 100% of it. If you want the red you might change the bgcolor of the menu to that. Also if you want the menu to be centered and not as wide as the page, you need to make the div less than 100% and then bracket it with center tags Hope that helps.

Ruth
dmj120
Advanced
Advanced
Posts: 17
Joined: Sat Jan 17, 2004 11:48 pm

Post by dmj120 »

thanks :D

now, however, i get 2 mens for each... what's the trick to get the extra menus off?? :?:
User avatar
Ruth
 Team
 Team
Posts: 8763
Joined: Thu May 15, 2003 5:02 am
Location: Yucaipa, CA
Contact:

Post by Ruth »

Then take all the codes for the Main Menu1 and take it out of the menu_data1.js
You forgot to take what you put in the div and table out of their respective menu_data files. So, now it's reading the code directly from the div and table cell and also getting it from the menu_data file. So, just delete out the main menu1 and the main menu from their files. Just leave the submenus in the files themselves.

Ruth
dmj120
Advanced
Advanced
Posts: 17
Joined: Sat Jan 17, 2004 11:48 pm

Post by dmj120 »

thank you VERY much
Post Reply