Finally applied via a $('element').combobox() as in the example code.
I use several comboboxes and I want to "empty" the value of, say, "combobox 3" if, say, "combobox 1" gets changed.
The problem is that I cannot find out the id of that element. The cause of this is that combobox is actually "converted" to an INPUT element that shows the current selection of the comboxbox/select and it doesn't have any attributes for identification.
For instance a typical INPUT shows like
- <INPUT class="ui-state-default ui-combobox-input ui-autocomplete-input ui-widget ui-widget-content ui-corner-left" title="" value="some value" autocomplete="off">
So, I can get this.tagName, but nothing that identifies the INPUT or even the SELECT that's tied to it.
I also tried to get info via $(this) and ui.item, but I'm not able to get an id or name.
Can I get this with some method/property of the autocomplete widget/combobox method?
Or should I, for instance, change the code and push some identifier in the title or class or a custom attribute? Probably in _create? Or something else?
Thanks!
Addition.
In a completely different approch I tried now something like
-
$('#tdOrt').hover()
where #tdOrt is the id of the td that surrounds the combobox area. That works for hover. But if I try to apply it to a form event it doesn't fire, e.g.
- $('#tdOrt span.ui-combobox input').change() (or blur())