This is my code to autocomplete. This one work well for the first word. But I need to filter other words also in the same search box. this is my code.
its working But I need to filter second word also. like Hello world Google. When user type hello its filter hello world. after that he type Google then i want to filter Google word
<div class="ui-widget">
<label for="tags">Search: </label>
<input type="text" id="tags" onkeypress="edValueKeyPress()"/>
</div>
$(function edValueKeyPress() {
var availableTags = [
"Hello",
"Hello World ",
"Google",
"Google Gmail",
"Micheal",
"Peter"
];
$( "#tags" ).autocomplete({
source: availableTags
});
})