Mura自定义表单验证的问题

时间:2018-06-14 02:12:32

标签: coldfusion mura

我在Mura的displayobjects中创建了一个名为myform.cfm的自定义文件,并在该表单中添加了表单代码。我正在使用jQuery Validator来使用jQuery的数据必需属性来验证表单,但它总是跳过验证。这是我的代码:

Mura(function(m) {
    window.customFormValidation = function(theform) {
        theform.validate({
            submitHandler: function(form) {
                Mura.submitForm(theform);
                return false;
            }
        });
        // let Mura process the form now
        //Mura.submitForm(theform);
        //return false;
    }
});

总是失败:

我在表单中添加了以下内容:

<form id="contact_form_request" name="contact_form_request" 
      data-autowire=true action="" method="post" 
      onsubmit="window.customFormValidation(this);return false;" novalidate>

0 个答案:

没有答案