Problems with menu staying where it should

Having problems with DHTML Menu? There is usually somebody here who knows the answer.
Post Reply
djdannyt
Beginner
Beginner
Posts: 2
Joined: Thu Mar 06, 2008 3:11 pm

Problems with menu staying where it should

Post by djdannyt »

Hi,

Please see link below:

http://www.advancedsupplychain.com/frontpage.htm

Upon viewing this, the menu sits nicely at the top of the page, but however if you were to double click the IE bar (to initiate a resize) or manually drag the window smaller or bigger the menu system doesnt sit where it should.

However if you refresh the page or hover themouse over one of the menu items its goes and sits back in place.

The menu is sitting inside a table and I cannot understand why this isnt working.

Any help would be appreciated.

Below is a snippet of the code i am using in the HTML page:

Code: Select all

<!-- ***** This is the section of code you need to paste into your web pages ***** -->
<script type="text/javascript" src="milonic_src.js"></script>	
<script type="text/javascript" src="mmenudom.js"></script>
<!-- The next file contains your menu data, links and menu structure etc -->
<script type="text/javascript" src="menu_data.js"></script>	
<!-- **** JavaScript Menu HTML Code -->
<table border=0 width=100%>
  <tr>
    <td  class=menu1> <script>
						with(milonic=new menuname("Main Menu")){
						style=menuStyle;						
						alwaysvisible=1;
						orientation="horizontal";
						overfilter="";
						position="relative";
						aI("text=Home;url=http://milonic.com/;status=Back To Home Page;");
						aI("text=Menu Samples;showmenu=Samples;");
						aI("text=Milonic;showmenu=Milonic;");
						aI("text=Partners;showmenu=Partners;");
						aI("text=Links;showmenu=Links;");
						aI("text=My Milonic;showmenu=My Milonic;");
						}
						drawMenus();		
						  </script>
    </td>
  </tr>
</table>
User avatar
John
 Team
 Team
Posts: 5967
Joined: Sun May 19, 2002 8:23 pm
Location: Phoenix, AZ
Contact:

Re: Problems with menu staying where it should

Post by John »

Another one of those pesky IE-only problems (I don't see the failure in FF).

However, first, your setup is not correct for using the menu in a td. Please see this page for instructions.
John
djdannyt
Beginner
Beginner
Posts: 2
Joined: Thu Mar 06, 2008 3:11 pm

Re: Problems with menu staying where it should

Post by djdannyt »

Hi, thanks for the response, but I have read the doucment and dont quite understand.

Could you explain more on the the fact that you think I am not used the td tag properly.

Thanks
Dan
User avatar
Ruth
 Team
 Team
Posts: 8763
Joined: Thu May 15, 2003 5:02 am
Location: Yucaipa, CA
Contact:

Re: Problems with menu staying where it should

Post by Ruth »

Hi,

Well, it seems you are putting the menu into a table cell. That means the menu is positioned 'relatively' and that requires a particular method to have it work correctly. Just putting the calls for the files into the table cell won't have it work correctly on all browsers.

1. You do not have the main menu set as position='relative';
2. Since you are putting all calls in the table cell you are required to use buildAfterLoad=true; in the top section

You can see both methods here, Method 1 is the new method and Method 2 the old one. http://support.milonic.com/beginners/ta ... /index.htm

The only thing to ignore in the example is program calls. Your calls for the files are fine, just make the required changes depending on which method you use with regard the data file.

Code: Select all

<script type="text/javascript" src="milonic_src.js"></script> 
<noscript><a href="https://milonic.com/">JavaScript DHTML Menu Powered by Milonic</a></noscript>
<script type="text/javascript" src="mmenudom.js"></script> 
<script type="text/javascript" src="menu_data.js"></script>
Ruth
Post Reply