I would like to wire up ALL forms so that a loader is shown after Jquery Validation has found no errors and before the form is submitted or on submit.
How can this be accomplished using MVC 4 unobtrusive validation?
I have tried the following as per this article, How to add a 'submitHandler' function when using jQuery Unobtrusive Validation?:
$("form").data("validator").settings.submitHandler = function (form) { alert('submit'); form.submit(); };
I placed this in the OnLoad section but this does not fire. I asume the above will work for all forms?
Thanks!