in doing a search function, the input box type is search, and form, is also set on the outside, but in the input process, the search button of the soft keyboard will become a confirmation button at certain times, and it is impossible to click the confirm button at this time. Have you ever encountered this situation? The
html code goes like this
<form action="">
<input type="search" placeholder="" class="searchProduct" id="searchProduct" autocomplete="off"/>
</form>
js contains several methods, all of which are invalid when you click OK.
$("form").on("submit", function(evt){
});
//
$(".searchProduct").keyup(function(evt){
if (evt.keyCode == 13) {
}
});
as long as it becomes a confirmation button, clicking confirmation has no effect at this time. Only deleting one or two words or adding one or two words will become a search. Usually, clicking confirm will become a search when you enter a letter, but it will become a confirmation under certain circumstances.