JQuery validation not working after form reset
<p>I'm having an issue after I reset my form using:</p>

<pre><code>$(".cancel").click(function () {
        validator.resetForm();
        $(':input', '#MyForm')
            .not(':button, :submit, :reset, :hidden')
            .val('')
            .removeAttr('checked')
            .removeAttr('selected');
        //OR
        document.getElementById('MyForm').reset();
});
</code></pre>

<p>When I hit save again, the required fields are no longer required and the form posts back. How can I get the form to re-validate even after a reset?</p>

<p>This is a simple example since I'm just resetting validation and the form, but on other pages I have to manually manipulate certain fields, so I need this way of resetting forms to work.</p>

<p>This is an MVC created form if that makes any difference</p>

<p>Any suggestions?</p>

<p><strong>EDIT:</strong> After some trial and error, it seems that the problem shouldn't lie with the direct resetForm code but rather something else.</p>

<p>In the console I get the following javascript error:</p>

<pre><code>SyntaxError: invalid label
</code></pre>

<p>and a warning</p>

<pre><code>Use of attributes' specified attribute is deprecated. It always returns true.
</code></pre>

<p>Not sure if they're related to my issue but not sure what else to do at this point.</p>

<p>As far as the scripts I'm using:</p>

<pre><code>@Scripts.Render("~/bundles/modernizr")
@Scripts.Render("~/bundles/jquery")
@Scripts.Render("~/Scripts/jquery-1.8.3.min.js")
@*@Scripts.Render("~/Scripts/jquery-1.9.1.min.js")*@
@Scripts.Render("~/Scripts/jquery-ui-1.9.2.js")
@Scripts.Render("~/Scripts/jquery.validate.js")
@Scripts.Render("~/Scripts/jquery-validate-messages.js")
@Scripts.Render("~/Scripts/jquery.validate.unobtrusive.min.js")
@Scripts.Render("~/Scripts/DataTables-1.9.4/media/js/jquery.dataTables.js")
@Scripts.Render("~/Scripts/jquery.jeditable.mini.js")
@Scripts.Render("~/Scripts/DataTables-1.9.4/media/js/jquery.dataTables.editable.js")
@Scripts.Render("~/Scripts/DataTables-1.9.4/extras/TableTools/media/js/TableTools.js")
@Scripts.Render("~/Scripts/Countdown.js")
@Styles.Render("~/Scripts/DataTables-1.9.4/media/css/jquery.dataTables.css")
@RenderSection("scripts", required: false)
</code></pre>

<p>1.9.1 was commented out because it was breaking on the first JQuery call. Is this related?</p>
