I am able to validate two fields using Max's code (checkequal)from another post. But, how can I validate two more fields on the same form. For example:
password
confirm_password
AND
email
confirm_email
Thanks,
Gabe
password
confirm_password
AND
confirm_email
Thanks,
Gabe
Hi Gabe,
This can be done by adding a class to your element:
Bob
This can be done by adding a class to your element:
validate['%checkEqual2']
and adding a JS snippet using a load JS action:function checkEqual2(el){
if (el.value != $('confirm_password').value) {
el.errors.push("Passwords are not the same!");
return false;
} else {
return true;
}
}
Where "confirm_password" is an id for the password confirmation field.Bob
This topic is locked and no more replies can be posted.