dsheiko / HTML5-Form-Shim

⛔️ [DEPRECATED] That is a jquery plugin, which emulates HTML5 Form Validation on old browsers. The plugin also allows to customize form submission validation tooltips and field validation callbacks (e.g. via XMLHttpRequest)
http://dsheiko.github.io/HTML5-Form-Shim/
71 stars 17 forks source link

Form never submits #3

Closed six8 closed 11 years ago

six8 commented 11 years ago

I've set this up on a regular form. Validation works fine. However, with all fields valid, when the user hits submit, nothing happens.

Unless I'm missing something, this is the culprit:

handleOnSubmit : function(e) {
                   e.preventDefault();

The default action (submitting the form) is prevented, validation happens, but even if the form is found to be valid, the submission is not continued.

webberig commented 11 years ago

My project is suffering the same faith. After implementation none of the forms work, they all get stranded on the same place as the OP.

After a quick read of the code, I think that e.preventDefault() should only be called whenever context.setInvalid(); is called...

dsheiko commented 11 years ago

Claimed to be fixed in ver. 2.0.x