I implemented autocomplete which fetch all data with ajax post from database and add them to autocomplete as item. which is shown below
jQuery.ajax({
url: "--url--",
dataType: 'jsonp',
success: function(data){
jQuery("#location_finder").autocomplete({
source: function( request, response ) {
var lookup = jQuery.ui.autocomplete.escapeRegex( request.term );
var matcher = new RegExp( "^" + lookup, "i" );
response( jQuery.grep(data, function(item){
return matcher.test(item);
}));
}
});
},
});
The data after post come as :
data = ['Berti','Simon','Çarli','Cherpa'];
While doing typing in input field for letter "C" only "Cherpa" shown but I try to show "Çarli" also to user. How can I handle it and give option to user both letter "C" and "Ç"? Thanks in advance.
You can try :