auto complete without error problem
Hi Team,
I was trying to create a auto complete using INPUT. i put the following javascript in mobileinput:
code
var searchRequest = null;
Appery('mobiletextinput_4').autocomplete({
maxLength: 5,
source: function(request, response) {
if (searchRequest !== null) {
searchRequest.abort();
}
searchRequest = $.ajax({
/* headers: {
'Accept': 'application/json',
'Content-Type': 'text/plain'
},*/
url: 'http://124.83.33.148:2020/phpWidgetSource/Empfinder.php',
method: 'POST',
dataType: "jsonp",
data: {term: request.term},
success: function(data) {
searchRequest = null;
response($.map(data.items, function(item) {
return {
value: item.Fullname,
label: item.Fullname
};
}));
}
}).fail(function() {
searchRequest = null;
});
}
});
Appery("mobiletextinput_4").autocomplete("enable");
Appery("mobiletextinput_4").autocomplete( "search", "" );
/code
add this library:
http://code.jquery.com/ui/1.10.3/jque...
and put css:
code
.ui-helper-hidden-accessible{
display:none;
}
ul.ui-autocomplete{
background-color:#fff;
z-index:3;
} /code
but no error in console,
encountered and no autocomplete is showing.
i hope you can help me here. thanks