The hidden field is added and the autocomplete functionality is implemented