adds autocomplete functionality to form