Got an odd behavior today when dealing with a form which has only one input.
The input binds to a js function to judge if it is key==13, we do tweak the input params and submit. However everytime we hit enter, even before executing the js function, the form has already been submitted to the server.
When there is only one single-line text input field in a form, the user agent should accept Enter in that field as a request to submit the form.
So to prevent this. a easy way is to put a hidden input box in the form.
Hide is just a bootstrap class which has