jQuery 1.9 Autocomplete 点击提示全部

 id="autocomplete"/>  id="submit" type="submit"/>

var source = ['One', 'Two', 'Three', 'Four'];

var firstVal = source[0];

$("input#autocomplete").autocomplete({
    minLength: 0,
    source: source
}).focus(function() {
    $(this).autocomplete("search", "");
});

你可能感兴趣的:(Jquery/ajax)