I haven't figured out exactly what is causing this - but when I put a Hierarchical Select field at the bottom of the form, it works fine - however if I move it to the top the select box ends up disabled in Firefox (it works fine in Chrome). The select box has disabled="" in firebug, so the code is obviously running, however the browser is not registering the change. My guess is this is some race condition. Removing the "disabled" attribute (rather than setting it to false) appears to work fine however - I think this must trigger a different DOM event.

CommentFileSizeAuthor
disabled_js.patch537 bytesOwen Barton
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Wim Leers’s picture

Status: Needs review » Fixed

I didn't commit this for alpha 2 because I vaguely remember problems with changing an element from disabled to enabled and vice versa, and the current code may have been a work-around. git-blame is not being very helpful (or maybe I'm using it incorrectly — first time I need it), so I can't be sure. I tried your change in Safari 5 and Chrome 10 (you tried it in Firefox) and it's working just fine. So probably, this is a safe change. Hence, I'm committing it.

Commit: http://drupalcode.org/project/hierarchical_select.git/commit/397b1cf.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.