Is it possible in javascript or Jquery to click on an input field in my case:
<input id="search" type="text" placeholder="...">
and push Enter
Is it possible in javascript or Jquery to click on an input field in my case:
<input id="search" type="text" placeholder="...">
and push Enter
I think you want to submit the form when the input is clicked so:
var input = document.querySelector('input'),
form = document.querySelector('form');
input.addEventListener('click', function(){
form.submit();
});
In terms of a form you can use JQuery post and get methods Example. $(#id).click(function (){ $.post("url", {variable}); });