Chapter 2: ColdFusion Functions
297
CreateDate
Returns a valid date/time object.
See also
CreateDateTime
and
CreateODBCDate
.
Syntax
CreateDate
(
year, month, day)
year
Number representing the year in the range 100–9999. Years from 0 to 29 are
interpreted as 21
st
century values. Years 30 to 99 are interpreted as 20
th
century
values.
month
Number representing the month of the year, ranging from 1 (January) to 12
(December).
day
Number representing the day of the month, ranging from 1 to 31.
Usage
CreateDate is a subset of
CreateDateTime
.
Time in the returned object is set to 00:00:00.
Examples
<!---------------------------------------------------------
This example shows how to use CreateDate, CreateDateTime, and
createODBCdate
----------------------------------------------------------->
<HTML>
<HEAD>
<TITLE>
CreateDate Example
</TITLE>
</HEAD>
<basefont face="Arial, Helvetica" size=2>
<body bgcolor="#FFFFD5">
<H3>CreateDate Example</H3>
<CFIF IsDefined("FORM.year")>
Your date value, presented using different CF date functions:
<CFSET yourDate = CreateDate(FORM.year, FORM.month, FORM.day)>
<CFOUTPUT>
<UL>
<LI>Built with CreateDate: #CreateDate(FORM.year, FORM.month,
FORM.day)#
Содержание COLDFUSION 4.5-CFML LANGUAGE
Страница 1: ...Allaire Corporation CFML Language Reference ColdFusion 4 5...
Страница 207: ...Chapter 1 ColdFusion Tags 183 CFCATCH CFTRY BODY HTML...
Страница 224: ...200 CFMLLanguageReference CFOUTPUT P Text within CFOUTPUT is always shown CFOUTPUT BODY HTML...
Страница 296: ...272 CFMLLanguageReference INPUT TYPE text NAME number2 BR INPUT TYPE submit NAME submit VALUE Add FORM BODY HTML...
Страница 336: ...312 CFMLLanguageReference CFIF BODY HTML...
Страница 404: ...380 CFMLLanguageReference DE It is morning CFOUTPUT P BODY HTML...
Страница 413: ...Chapter 2 ColdFusion Functions 389 Customer BalanceDue BR CFOUTPUT CFIF BODY HTML...
Страница 483: ...Chapter 2 ColdFusion Functions 459 CFOUTPUT CFLOOP BODY HTML...
Страница 557: ...Chapter 2 ColdFusion Functions 533 P CFOUTPUT Value i is employee keysToStruct i CFOUTPUT P CFLOOP CFIF BODY HTML...
Страница 584: ...560 CFMLLanguageReference...
Страница 594: ...570 CFMLLanguageReference...