Hi, I have two issues.
- When trying to set form validation for a field, I cannot find the option in the input element’s settings to introduce validation. This article ( https://support.wix.com/en/article/validating-user-input-with-settings ) says it should be possible but I just don’t see the option.
- When trying to do custom form validation with Corvid, my website does not flag invalid input and submits the form and takes the user to the next page. My code is below:
$w("#input5").onCustomValidation( (value, reject) => {
if(value === "water") {
reject("Water is not valid");
}
} );
Alternatively, if I check that the input is not a certain value, it always returns that the input is wrong, even when it should be valid:
$w("#input5").onCustomValidation( (value, reject) => {
if(value !== "water") {
reject("Answer is incorrect");
}
} );
Any help on either of these issues is much appreciated!