skip to Main Content

Autocomplete from fields above – Jquery

I have this form: <form> <input type="text" class="name" id="name1"> <input type="text" class="name" id="name2"> <input type="text" class="name" id="name3"> ... <input type="text" class="name" id="name100"> <input type="submit" value="Send"> </form> <script> $(document).ready(function() { var items = [ "", ]; $(".name").autocomplete({ source: items }); $('.name').on('keyup',…

VIEW QUESTION

Autocomplete with jQuery

I have been trying to build a simple jQuery Autocomplete. The ajax query returns a JSON String formatted like this below [[{"stockkeepingunitname":"LIT","stockkeepingunitid":"627d3240-174d-11ed-a08e-f3a5c3baaa0d"},{"stockkeepingunitname":"LKTTT","stockkeepingunitid":"8fb03b68-1752-11ed-adc9-4f54c8003b1e"},{"stockkeepingunitname":"TBN","stockkeepingunitid":"f0825efe-173d-11ed-a983-1ff727e3bf1b"}]] Then I pass it to the AutoComplete functions as below. $('#stockKeepingUnit_StockKeepingUnitName').autocomplete({ source: function (request, response) { $.getJSON("/ajax/GetStockKeepingName/?strStockKeepingName=" +…

VIEW QUESTION
Back To Top
Search