I\'m requesting an ASP.net MVC view into a live box and the view contains form fields that have been marked up with attributes to be used by JQuery\'s unobtrusive validators
For some reason I had to combine bjan and dfortun's answers...
So I put this in my view:
@{
this.ViewContext.FormContext = new FormContext();
}
And this execute this after the ajax call finishes:
var form = $("#EnrollmentForm");
form.unbind();
form.data("validator", null);
$.validator.unobtrusive.parse(document);
form.validate(form.data("unobtrusiveValidation").options);