Problem with a Javascript website menu

I’m a student assistant to a professor at my university, and one of my jobs is to host the chair’s website.

We use a free Javascript menu called “coolmenu” in the top frame of a three-frame website. It’s basically a Java-based dropdown menu: You click one of the main items, and a submenu with several items which belong to that superior one drops down. Clicking one of the main items will also link to an html site on this item, the submenu items will link to different sites. It’s supposed to work like this (that’s the top frame from the webiste of another chair, which uses the same system).

Occasionally, I make modifications to this menu to add or delete submenu items, without changing the Javascript structure itself. Usually, this works just fine without any problems. Since a few days, however, I’m experiencing problems with the menu, most likely from a mistake of mine in the last modification, but I just don’t get what I did wrong.

Now, the result I get when I try to access the menu in a browser is this - a German note saying that the browser doesn’t support Javascript (which isn’t true, as the menu on the other webiste works just fine), together with a link to an auxiliary menu which is not Java-based and works, but is less cool. The latter one is the one I implemented on the homepage (here , if you’re interested in German civil law), simply because it works, but I’d be glad to have the Javascript one back working.

I made a number of attempts to correct this by copying and modifying the source code of the working menu of the other chair, and I came up with this site, which has the desired menu and submenu structure, but it’s not clickable - nothing happens when you click it. I suspect it has something to do with the “menu_def.js” file which is linked to in the header of the menu file, but I never modified that one, and when I opened it it didn’t seem to me as if this site needed to be adapted to the menu structure of the menu site. I guess it simply provides source information for the langauge, the taylor-made adaptation to your own site happens entirely on the menu site itself. Nonetheless, it doesn’t work, although I got a copy of the menu_def.js file from the other chair.

I’m pretty much confused because I can’t explain where the mistake is. I’d be happy and grateful if any dopers were kind enough to take a few minutes to look at the codes and dare a guess on what might be wrong.

Personally, since I hate pouring through other peoples’ code, I’d just go with something simpler like Son of Suckerfish, but that’s mostly because I’m really, really lazy. :wink:

Which of those links is supposed to have a working menu with items that drop down? I’m using Firefox and none of those pages has a dropdown menu…

But, anyway, your problem is that one of your items has a ’ in it. Int’l Aspects of IP Law. You can’t have that within other single quotes… ‘Int’l Aspects of IP Law’ … See how it would confuse the browser as to where the beginning and the end of the item is?

Anyway, change it to ‘Int’l Aspects of IP Law’

But I think you need to implement a new menu. This one was made in 2001 and doesn’t seem to support Firefox.

I lost a day trying to get Suckerfish working on a Joomla website. It looked really good, until you refreshed the page and my horizontal menu turned into a vertical one :frowning:

I gave up.

Si

Yeah, the css is a bit touchy. On a current project I spent an hour and a half trying to figure out why IE 7 started chugging on a two level submenu but Firefox was fine. Turned out that IE hates having an li defined as “100%” of its parent–you have to specify the width exactly.

It’s still the most straightforward I’ve seen so far. It’s also pretty compatible and degrades beautifully on browsers that don’t support css–basically just turns into a neat list of site links.

Actually, it was FF giving me grief. A CTRL-R (refresh CSS) was ok, it was F5 (refresh HTML) that screwed up.

IE was fine, but I don’t use IE and I didn’t want to risk customers having a problem (this is for our small business).

Si

If you load the menu frame separately, then you’re right, but if you load the entire website with its three pages (example, then the dropdown menu will appear when the cursor hovers over one of the top items, but only if you’ve already clicked any of the items in the top menu (at least that’s how it works with my machine, and I’m using Firefox too).

But more importantly, you’re right about the problem being the apostrophe in Int’l Aspects of IP Law. I wasn’t aware that this would confuse the browser due to the apostrophe’s meaning in the syntax of the script. Thank you so much, and thanks to verybody else for their help!

Try these sites

http://dynamicdrive.com/

or

They have message boards and free scripts the rock.