Given the following:
$("#dataField").focus().autocomplete({
minLength:5,
cache:false,
source:"${request.contextPath}/ajaxActions/getdata",
select:function (event, ui) {
populateForm(ui);
}
});
How could I change the focus function such that it would place the cursor at the end of the input’s current value?
I haven’t actually tested this, but it should more or less do what you need.
For actually moving the cursor, see this SO question: move cursor to the beginning of the input field?