diff options
author | Felix Nagel <info@felixnagel.com> | 2011-06-07 01:07:04 +0200 |
---|---|---|
committer | Felix Nagel <info@felixnagel.com> | 2011-06-07 01:07:04 +0200 |
commit | f2865c1f51c70e71b28043d6a2e317f5cad099b6 (patch) | |
tree | ad243715ee2a075aa140677abe818b3b6d84c593 | |
parent | 0138aef4a886697f4033cc33052964b7eff4f069 (diff) | |
download | jquery-ui-f2865c1f51c70e71b28043d6a2e317f5cad099b6.tar.gz jquery-ui-f2865c1f51c70e71b28043d6a2e317f5cad099b6.zip |
fixed: problem (mainly in <= IE7) when select has no id, thx Ryzo and cburgdorf, see: https://github.com/fnagel/jquery-ui/issues/101
-rw-r--r-- | ui/jquery.ui.selectmenu.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/ui/jquery.ui.selectmenu.js b/ui/jquery.ui.selectmenu.js index 70c5d9ff0..061a979e3 100644 --- a/ui/jquery.ui.selectmenu.js +++ b/ui/jquery.ui.selectmenu.js @@ -68,9 +68,9 @@ $.widget("ui.selectmenu", { this.newelement.prepend('<span class="' + self.widgetBaseClass + '-status" />'); // make associated form label trigger focus - $('label[for="' + this.element.attr('id') + '"]') - .attr('for', this.ids[0]) - .bind('click.selectmenu', function() { + $( 'label[for="' + selectmenuId + '"]' ) + .attr( 'for', this.ids[0] ) + .bind( 'click.selectmenu', function() { self.newelement[0].focus(); return false; }); |