关于autoComplete 的source的设置
刚工作,因需求要用到autoComplete。
看到它的选项source的配置。
Type: Array or String or Function( Object request, Function response( Object data ) )
Default: none; must be specified
Array: An array can be used for local data. There are two supported formats:
An array of strings: [ "Choice1", "Choice2" ]
An array of objects with label and value properties: [ { label: "Choice1", value: "value1" }, ... ]
我主要想source从数据库中获得数据,并返回第二数组类型 [ { label: "Choice1", value: "value1" }, ... ]
感觉没有头绪。哪位大神能简单实现代码让我观摩一下。
就是source:XXXXXX.jsp
XXXXX.jsp里面怎么写。如何从数据库中得到值可以省略,我想看到从数据库中得到值之后,怎么处理并返回给source的。
谢谢大家了
看到它的选项source的配置。
Type: Array or String or Function( Object request, Function response( Object data ) )
Default: none; must be specified
Array: An array can be used for local data. There are two supported formats:
An array of strings: [ "Choice1", "Choice2" ]
An array of objects with label and value properties: [ { label: "Choice1", value: "value1" }, ... ]
我主要想source从数据库中获得数据,并返回第二数组类型 [ { label: "Choice1", value: "value1" }, ... ]
感觉没有头绪。哪位大神能简单实现代码让我观摩一下。
就是source:XXXXXX.jsp
XXXXX.jsp里面怎么写。如何从数据库中得到值可以省略,我想看到从数据库中得到值之后,怎么处理并返回给source的。
谢谢大家了
...全文
相关推荐
jQuery-Autocomplete-master
文本自动填充,http://blog.csdn.net/linlinv3/article/details/38516661 可以看具体例子,官网写的太含糊了。
jquery的autocomplete(自动补全)插件
1.该js支持jquery的自动补全功能 2.因为jquery-ui是jquery的插件,所以部分版本jquery可能不支持该插件,建议换成内附的jquery.js 3.如有疑惑,请阅读内附的说明文档
AutoComplete源代码
delphi编写的AutoComplete源代码delphi编写的AutoComplete源代码
jQuery AutoComplete使用实例
NULL 博文链接:https://demojava.iteye.com/blog/791962
jquery-autocomplete 自动填充插件参数使用说明
NULL 博文链接:https://canrry.iteye.com/blog/750679


