When my js page loads and I create a rule seen below I get a error thrown from the jquery.validate.js library line #138, that says "cannot read property 'settings' of undefined"
settings = $.data( element.form, "validator" ).settings;
Here is the rule I'm adding and the form I'm adding it too
$('#zipCodeText').rules("add", { required: true, minlength: 5, maxlength: 5, messages: { required: "Required input", minlength: jQuery.validator.format("Please, {0} characters are necessary"), maxlength: jQuery.validator.format("Please, {0} characters are necessary") } });
@using (Html.BeginForm("SaveLocation", "Manage", FormMethod.Post, new { @class = "form-horizontal", @id = "registerForm", role = "form" })) {
@Html.EnumDropDownListFor(m => m.Countries, null, new { @id = "countryList", @class = "selectpicker btn-group-lg" }) }