View Full Version : ddsmoothmenu sometimes shows 'loading menu'

04-15-2010, 03:04 AM
1) Script Title:

2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex1/ddsmoothmenu.htm

3) Describe problem:

I installed the menu on the site 1099fire.com.

When I go to the home page, or subpages, the menu sometimes
shows 'Loading menu' and it just doesnt display the menu. I reboot or
try a different computer and it will probably work, but that 'Loading menu' thing really has me worried that it might be not showing up more often for
other people as well.

Has any one experienced this? Did I install it correctly? Is there
anything I can do to guarantee that it will display? Or display more

Please, any response any one can give me will be greatly appreciated.

Danielle Brina

04-15-2010, 05:54 AM
The reason is due to the path you've specified to the external menu page, by using a full absolute URL:

contentsource: ["smoothcontainer", "http://www.1099fire.com/menu/smoothmenu.htm"] //"markup" or ["container_id", "path_to_menu_file"]

When users go to http://1099fire.com (without the www), it's treated as a different domain than the "www" version, resulting in an Ajax error. You should either use a relative URL to the webpage, such as:

contentsource: ["smoothcontainer", "menu/smoothmenu.htm"] //"markup" or ["container_id", "path_to_menu_file"]

or have JavaScript dynamically write out the domain portion of it:

contentsource: ["smoothcontainer", window.location.hostname+"/menu/smoothmenu.htm"] //"markup" or ["container_id", "path_to_menu_file"]