Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!


2 years 9 months ago #201462 by Steven123
VALIDATIONS was created by Steven123

Kindly assist me to validate the calender not to allow today's date when a user selecting Birth date.

Also assist me to validate a field i call Identity number which is controlled by gender(male or female),Identity number has 9 digits the middle number is either 1 or 2 depending on the gender selected.

The topic has been locked.
2 years 9 months ago #201466 by Joffm
Replied by Joffm on topic VALIDATIONS
1. self!=date("Y-m-d 00:00")

2. regexMatch('/^[0-9]{4}[1|2][0-9]{4}$/',self.NAOK) }

Volunteers are not paid.
Not because they are worthless, but because they are priceless
The following user(s) said Thank You: Steven123
The topic has been locked.
2 years 9 months ago #201480 by DenisChenu
Replied by DenisChenu on topic VALIDATIONS
And with max date "now" or "today" ?

Thisnk it's better : you can not set a birthdate to tomorrow …

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose