Dear Support,
We just purchased metabox development version. It is very useful. In one of our website we need to use the metabox extension MB Frontend Submission & created a form. Now we need to validate the fields and your default validation rules came to help mostly, but we need to create a custom validation rule/method and had some experience creating them with addMethod function when I was using jquery validation plugin you mentioned, but it gives me error when I am trying to define a new rule with addMethod
. Can you please help me in this?
Note: the error message is Uncaught TypeError: Cannot read property 'addMethod' of undefined at HTMLDocument.<anonymous>
when I am writing the code as follows
$.validator.addMethod('checkXiiAggregate',function(element, value){
if (check_all_XII_fields_empty())
if ( element == "") return true;
if ($("#cmbclassxiiyearofpassing").val() != $("#lte_current_year").val()) {
if (element == ""){
return false;
}
}
return true;
}, "Please provide aggregate marks.")
Thanks in advance