O'Reilly logo

jQuery in Action, Second Edition by Yehuda Katz, Bear Bibeault

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

11.4.3. Autocomplete events

During an autocomplete operation, a number of custom events are triggered, not only to inform us of what’s going on, but to give us a chance to cancel certain aspects of the operation.

As with other jQuery UI custom events, two parameters are passed to the event handlers: the event and a custom object. This custom object is empty except for auto-completefocus, autocompletechange, and autocompleteselect events. For the focus, change, and select events, this object contains a single property named item, which in turn contains the properties label and value, representing the label and value of the focused or selected value. For all the event handlers, the function context (this) is set to the <input> element.

Table ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required