Good Day,
I have a web form that is using this awesome plugin and I'm trying to set up a rule. In my form, I have a Quantity field. If the Quantity field is set to 1 AND a checkbox is checked, then I want to validate a field.
My form is setup like:
Quantity TEXTBOX id = txtQuantity
Gift? CHECKBOX id = #other
Recipient TEXTBOX id = txtRecipient
and my jQuery code is:
txtQuantity: "required",
txtRecipientEmail: { required: "#other:checked" },
I tried:
txtRecipientEmail: { required: "#other:checked", required: "$('txtQuantity').val() == '1'" }
but that's not working
Is there another way to do this?
TIA,
coson