in my form I have my button like this
<button id="mybutton" type="submit"></button>
I am using query submit to submit the form
$('#mybutton').click(function()
{
$('form#myform').submit();
}
It works for most besides when I hit enter it still submits the form totally by passing the click catch. I changed button type to button
<button id="mybutton" type="button"></button>
but then it doesn't do anything when I hit enter.
I heard I could use bind or on but not sure how would that help me in this case. Any help will be appreciated EDIT
If I change the button type from submit TO button, then it does not do anything when I press enter. then I have to manually click the button. If I leave the type to submit it submits my forms on enter by passing jquery net.