Fix: Use a better way to bold search criteria (no use of javascript regex, but use php regex). Usage of * was making javascript crazy.

Fix: When field is manually cleaned, we must also clean hidden fields.
New: Can define number of char before showing first answer
This commit is contained in:
Laurent Destailleur 2010-10-11 21:32:54 +00:00
parent 921aac798e
commit 1aead23242

View File

@ -121,6 +121,7 @@ function ajax_autocompleter($selected='',$htmlname,$url,$option='')
jQuery("#'.$htmlname.'").val(item.key);
}
var label = item.label.toString();
//label = label.replace(new RegExp("("+request.term+")","i"),"<strong>$1</strong>");
return { label: label, value: item.value, id: item.key}
}));
}, "json");