I have bundled jquery Validate scripts like :
bundles.Add(new ScriptBundle("~/bundles/jqueryval").Include(
"~/Scripts/jquery.unobtrusive*",
"~/Scripts/jquery.validate*"));
and am rendering in the _Layout as
@Scripts.Render("~/bundles/jqueryval")
But when i try to Validate my form on button click like :
$("form").validate({
errorPlacement: function (error, element) {
error.insertAfter(element).css("display", "inline");
}
});
Its giving me the error like :
0x800a01b6 - JavaScript runtime error: Object doesn't support property or method 'validate'
So anyone suggest me for this problem.