Skip to content

Conversation

dkordik
Copy link

@dkordik dkordik commented Sep 19, 2014

When you press enter on an input inside of a form, the browser fires a submit event on the form, and also fires a click event on the first submit button of the form, if there is one. elements default to type "submit" if a type is not specified.

This behavior is illustrated in this jsfiddle: http://jsfiddle.net/dkordik/y25r4qnp/

Closes #65

When you press enter on an input inside of a form, the browser fires a submit event on the form, and also fires a click event on the first submit button of the form, if there is one. <button> elements default to type "submit" if a type is not specified.

This behavior is illustrated in this jsfiddle: http://jsfiddle.net/dkordik/y25r4qnp/

Closes bitovi#65
@justinbmeyer
Copy link
Member

Wow ... I was not aware of that. Good catch!

@nitish754
Copy link

really dont know that . thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Submitting a form should fire click on first submit button

3 participants