You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a validate: $("div[name='birthday-form']").addClass("validate[required], custom[checkbirth], custom[checkbirthyear], custom[checkbirthmonth], custom[checkbirthday]");
But I don't want to display the 'required' error anymore, so I changed the validation to $("div[name='birthday-form']").addClass("validate[custom[checkbirth], custom[checkbirthyear], custom[checkbirthmonth], custom[checkbirthday]]"); but now it doesn't show the error message. Do you know why?
The text was updated successfully, but these errors were encountered:
I have the same problem, so I used another approach: funcCallRequired.
validate[funcCallRequired[checkbirthyear]]
For the function, when it's correct, it needs to return undefined. I'm not sure if this is the best way to do it, but it works for me.
function checkbirthyear() {
const birthyear = $("#" + "birthyear").val();
let msg = isValidYear(birthyear);
if (msg) {
return msg;
} else {
// This is needed to prevent the error message from showing when it's correct.
return undefined;
}
}
I have a validate:
$("div[name='birthday-form']").addClass("validate[required], custom[checkbirth], custom[checkbirthyear], custom[checkbirthmonth], custom[checkbirthday]");
But I don't want to display the 'required' error anymore, so I changed the validation to
$("div[name='birthday-form']").addClass("validate[custom[checkbirth], custom[checkbirthyear], custom[checkbirthmonth], custom[checkbirthday]]");
but now it doesn't show the error message. Do you know why?The text was updated successfully, but these errors were encountered: