<input id="captcha_code" type="text" class="form-control captcha" name="captcha" maxlength="4" required>
password: {
validators: {
notEmpty: {
},
stringLength: {
min: 6,
max: 24,
}
}
},
captcha: {
validators: false
}我有一个使用bootstrapValidator的登录表单,有一个captcha字段
我已经为这个字段设置了maxlength 4&必需的。我需要验证器跳过和不验证这个字段。(因为当用户输入错误的captcha代码时,它仍然显示滴答,因为长度是正确的)
发布于 2017-03-20 03:33:06
通过在required上设置input,您将告诉验证器它需要验证字段。
如果不希望验证器处理此字段,请同时删除required和maxlength,然后使用onchange或onsubmit处理程序或其他方式处理检查自己的值。
发布于 2019-05-22 13:55:08
使用此选项禁用captcha:{ enabled:false }
https://stackoverflow.com/questions/42895324
复制相似问题