... I am setting this to minor, since I've had it for a long time and I only realized it has to do with these two modules just today. I am using latest 6.x dev versions of both modules on D6.16, but I had it on D6.15 as well before upgrading.

So... I have two HS taxonomy drop-down menus exposed in a view. One is multi-level and the other one a simple one. I use DHTML Menu on the navigation menu placed on a sidebar. All menus display fine and work fine (another reason why this issue is set to 'minor'). When I select an item (term) from any of the HS menus and then click on a menu item from the navigation menu that has sub items (like the 'Create content' menu for example), the menu 'jumps' up-n-down once. If I select a second item from the HS menu and then click on the navigation menu, it 'jumps' up-n-down twice. If I select a third item, it does it three times. And so on I guess...

Now, DHTML Menu also has this 'Cloned Menu Link' feature that...

At the top of each menu, an extra link will be generated that leads to the page of the parent item.

This helps because clicking on a menu item with sub-items (parent item), will have the link perform the menu-unfolding effect and not take you to the item's link. Clicking on the generated menu link takes you to that menu and saves the day. Well, with this bug, each time a HS menu item is selected, another Cloned Menu Link is generated. If you clicked three times on any HS menu, you'll end up with three same menu links. So this is another side-effect of the same issue.

I know this might be hard to understand, so I'll make a screencast as soon as I can. It'll take some time, because since I am doing a screencast I might as well do it on a vanilla setup so I can be sure it's only these two modules that cause it. I am curious as to if anyone else has been experiencing this(?).

PS: this might turn to be a DHTML Menu issue and need to be taken there. Lets see...

Comments

Wim Leers’s picture

Project: Hierarchical Select » DHTML Menu
Component: Code » Javascript code

DHTML Menu is probably doing something wrong with Drupal.behaviors. Moving to the DHTML Menu issue queue.

klonos’s picture

Did you have the time to test/reproduce/confirm this or are you simply guessing Wim? I am asking because I think I can find some time to test in a vanilla setup and perhaps provide a screencast. I know I promised to do so almost half a year back, but it somehow slipped my radar.

Let me know.

PS: Given the fair amount of users of both modules, it is disturbing that nobody else got into this. But then again, this is a pretty specific use case scenario :/

cburschka’s picture

Thanks for reporting this.

This bug sounds like one that happened before when an AJAX request resulted in all behaviors being repeatedly rerun. I added a few lines to prevent the behavior function being run more than once.

// Do not run this function more than once.
if (Drupal.dhtmlMenu.init) {
    return;
}
else {
    Drupal.dhtmlMenu.init = true;
} 

This code is in the 6.x-3.x-dev version, but not in the 6.x-4.x-dev version, probably because it was backported from the D7 rewrite, which did not have to deal with this problem. D7 makes behaviors more elaborate and gives them specific "attach" events that are only run once.

You say you're using the D6 dev version, but this issue is tagged 6.x-3.x-dev. Could you make entirely sure whether you have the DRUPAL-6--3 branch or the DRUPAL-6--4 branch? Specifically, whether the first line of dhtml_menu.js is

for 3.x-dev:

// $Id: dhtml_menu.js,v 1.18.2.9 2008/11/21 13:14:53 arancaytar Exp $ 

or, for 4.x-dev:

// $Id: dhtml_menu.js,v 1.47.2.1 2009/11/07 00:13:52 arancaytar Exp $ 

and whether the above fragment is in the file?

If it's 4.x-dev, it just has to be added again; if it's 3.x-dev, then there's a deeper problem.

klonos’s picture

I've completely rebuild that setup since then, but I know how to reproduce this. Let me setup a new d6 site and check it out...

klonos’s picture

...I've dumped the db and done a new installation from scratch around May. I do keep a couple of dev versions of all my modules backed up in case I need to revert if things go wrong. Right now, I have a 6.x-3.x dev from 2009-Nov-16, one from 2009-Dec-07 and a 6.x-4.x dev from 2009-Dec-07 too.

The header of the .info file in the site with the issue was: ; $Id: dhtml_menu.info,v 1.9.2.1 2009/11/07 00:13:52 arancaytar Exp $ and it is the 4.x version.

Anyways, I'll do the setup from scratch using latest devs of both modules involved (DHTML Menu and HS) as I promised + create a step-by-step guide to reproduce the issue. I'll also let you know if the code from #3 solves the issue. Please stand by...

prajila.v.p’s picture

I am also experiencing the same issue with Drupal 7. The option Cloned Menu Link: At the top of each menu, an extra link will be generated that leads to the page of the parent item not working at all.

vuil’s picture

Version: 6.x-3.x-dev » 7.x-1.x-dev

I switch the issue to 7.x-1.x for check, test and contribution...

vuil’s picture

vuil’s picture

Status: Active » Closed (outdated)

I close the issue as Closed (outdated) because it is not present on current default 7.x-1.x (dev) branch. Please reopen it if still present at some point.