开发者

extend jqueryui autocomplete

How can I take use of the autocomplete functions to match the following requirements?

  • If suggestion matches more than 10 items, it should i开发者_开发技巧nstead of showing the suggestions, show the number of entries next to the input

  • If suggestion matches less than 10 items, it should suggest the autocompletion

I'm new to jquery and jqueryui, but is it right that I can control the "open" event to achieve my requirements? Can anyone help me out here, please? :D


Here you have an example: http://jsfiddle.net/marcosfromero/wD9RH/

You should use the callback option for the source parameter.

Read Overview in Autocomplete documentation page to understand how to use it:

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜