[英]How to : jQuery autocomplete for multiple valules with “;” semicolon separator support
我已經將this.value = terms.join( "; " )
行從逗號(,)更改為(;),這對我來說是一個很好的建議。 但是在分號后輸入新單詞時沒有顯示任何建議。我已經下載了jQueryUI演示
select: function( event, ui ) {
var terms = split( this.value );
// remove the current input
terms.pop();
// add the selected item
terms.push( ui.item.value );
// add placeholder to get the comma-and-space at the end
terms.push( "" );
this.value = terms.join( "; " );
return false;
}
function split( val ) {
return val.split( /\;\s*/ );
}
像我上面寫的那樣更改此功能...
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.