Question
Date validation options
Hi all,
Is there an EASY way to enter an acceptable date range for the following scenarios:
1. Participants must be over 18 - so their date of birth entered should fall before: today's date minus 18 years
2. Participants child must be between 2 weeks and 12 months old - so their baby's dob should fall between: today's date minus 2 weeks and today's date minus 52 weeks
If the dates entered do not fall between the validation dates I would like an error message to appear saying "Please check the dates entered. Please note you must be over 18 with an infant aged 2 weeks to 12 months to participate in this study."
Having no knowledge of how to write JS, how might I do that? I would have thought it would be a standard function however the validation only seems to allow for the format of the date, not a range. I've looked at the library and can't see that there's an option there but please correct me if I'm wrong. Also, I've looked at custom validation and can't see that entering a range is possible there either?
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.
