UMD Web Site

Page Content   Main Links   Page Links   Utility Links   Search   Footer Links

ColdFusion Development Project

cf_validatedate

Description: Creates select lists for month, day, and year. The form field names, pre-selected date, and the range of years can be specified as parameters.
Syntax:
<cf_validatedate
  checkday = "day"
  checkmonth = "month"
  checkyear = "hour"
  fromyear = "min_year"
  toyear = "max_year">
See also: cf_selectdate, cf_selecttime
Attributes:
Attribute Name Required/Optional Default Description
checkday required
Numeric day in the range of 1 to 31 of the date that should be validated.
checkmonth required
Numeric month in the range of 1 to 12 of the date that should be validated.
checkyear required
Numeric year in the range of fromyear to toyear of the date that should be validated.
fromyear optional current year Minimum allowed year value for the date that should be validated.
toyear optional current year Maximum allowed year value for the date that should be validated.
Returns: A result variable validdate is created as local variable in the calling page. The values are:

validdate = 0 for an invalid date
validdate = 1 for a valid date
Example:
<cf_validatedate checkday="31" checkmonth="2" checkyear="2000"
                 fromyear="1990" toyear="2010">
returns 0, since February 2000 didn't have 31 days.
<cf_validatedate checkday="29" checkmonth="2" checkyear="2000"
                 fromyear="1990" toyear="2010">
returns 1, since this is a correct date.

Contact Info:

Email: webdevelopment@umassd.edu - Web Design & Development

Main Links

Page Links

Utility Links

Search

 
Text Only Options

Top of page


Text Only Options

Open the original version of this page.

Usablenet Assistive is a UsableNet product. Usablenet Assistive Main Page.