sil*_*.it 6 javascript typeahead.js x-editable twitter-bootstrap-3
我试图将Bootstrap3与令人敬畏的x-editable和typeahead.js集成,但我无法使其工作:
我尝试了以下内容
但没有运气.
HTML代码:
<div style="margin: 150px">
    <a href="#" id="username">Rome</a>
</div>
JS代码:
$('#username').editable({
    mode: 'inline',
    showbuttons: false,
    type: 'text',
    url: '/post',
    pk: 1,
    title: 'Enter an Italian city',
    typeahead: {
        local: ['Rome', 'Milan', 'Venice', 'Florence']
    }
});        
在这里小提琴:http://jsfiddle.net/Ggxbm/3/
甚至http://vitalets.github.io/x-editable/docs.html#typeaheadjs提供的例子也不适用于我
我究竟做错了什么?
您需要包含typeahead.min.js 和typeaheadjs.js
你可以在此看到小提琴http://jsfiddle.net/9q7Jd/1/加入
http://cdnjs.cloudflare.com/ajax/libs/x-editable/1.5.0/inputs-ext/typeaheadjs/typeaheadjs.js
正在解决这个问题.
你可以在zip目录中找到typeaheadjs.js input-ext/typeaheadjs:https: //github.com/vitalets/x-editable/tree/master/src/inputs-ext/typeaheadjs
| 归档时间: | 
 | 
| 查看次数: | 4394 次 | 
| 最近记录: |