[phorm] [Phorm:] Re: date validation
- From: webbbs@xxxxxxxxx
- To: support@xxxxxxxxx
- Date: 29 Aug 2004 03:09:06 -0000
The following new message has been posted on Phorm Support Forum at
<http://www.phorm.com/support/>.
***************************************************************************
MESSAGE: (#4308) Re: date validation
<http://www.phorm.com/support/?rev=4308>
AUTHOR: Charles
DATE: August 28, 2004 at 11:09 p.m. EST
Reply To: (#4302) Re: date validation
Author: Holotech
Date: August 27, 2004 at 2:23 p.m. EST
I could not get some of the sophisticated REGEX stuff to work (calculates leap
year stuff). This is what I ended up using:
RULE: datefromVALID
CRIT: REGEX
ARGS: ^((0?[1-9])|(1[0-2]))/((0?[1-9])|([12][0-9])|(3[01]))/[0-9]{2,4}$
FFLD: datefrom
MESG: - starting date, must be mm/dd/yyyy format.
###
it only allows 1-12 for the mm field and 1-31 for the dd field. Also, it
allows yy or yyyy variations.
> If all you want to do is require it to be in m/d/yyyy
> format, use the REGEX criterion:
> CRIT: REGEX
> ARGS: ^[0-9]{1,2}/[0-9]{1,2}/[0-9]{4}$
***************************************************************************
This is an automatically-generated notice. If you'd like to be removed from
the mailing list, please visit Phorm Support Forum at
<http://www.phorm.com/support/>, or send your request to webbbs@xxxxxxxxxx If
you wish to respond to this message, please post your response directly to the
board. Thank you!
-------------------------------------------------
You are receiving this message because you are subscribed to the Phorm mailing
list. To send messages to the mailing list, simply send email to
phorm@xxxxxxxxxxxxx from the address you have subscribed. You may unsubscribe
from the list by sending email to phorm-request@xxxxxxxxxxxxx with
'unsubscribe' in the SUBJECT field.
Other related posts: