Date validation - only older than 18 allowed

  • Profile Image
    cordovacouncil
    Asked on June 08, 2015 at 10:45 AM

    I tried to limit the date of a submission to be no later than a certain date (1996/12/31) but I get an invalid date error when I test it.  What I'd really like to do is make sure someone is 18 years or older at time of submission. Is it possible to check this condition?

  • Profile Image
    Boris
    Answered on June 08, 2015 at 12:14 PM

    Hello cordovacouncil.

    You have implemented it correctly, but you've accidentally placed the date into the "Dates disabled before this date", which means that you have disabled those that are over 18 years.

    Simply move that date to the End Date field, and those that are younger than 12-31-1996 will not be able to enter their date of birth.

    At the same time, I would advise you to disable the Calendar Popup (set it to No), as it automatically pops up with the current date - so they would need to click 25 times to go 25 years back from 2015 to 1990 - for example. It is probably easier for them to simply type the date without the Calendar Popup.

    Please let us know if you need further assistance, we will be happy to help.