Name
ParseDateTime
Synopsis
ParseDateTime(datestring
[,conversiontype
])
Returns a valid ColdFusion date/time object from
datestring
. An optional
conversiontype
may be specified. Valid
entries for conversiontype
are
POP
and Standard
(the default).
If POP
is specified,
datestring
is converted to GMT (Greenwich
Mean Time) using the English (U.S.) locale. If
Standard
is specified, no conversion is performed.
Examples:
<CFOUTPUT> <B>ParseDateTime("Sat, 15 Aug 1998 19:00:00 +0400", "POP"):</B> #ParseDateTime("Sat, 15 Aug 1998 19:00:00 +0400", "POP")#<BR> <B>ParseDateTime("Sat, 15 Aug 1998 19:00:00 +0400 (EDT)", "POP"):</B> #ParseDateTime("Sat, 15 Aug 1998 19:00:00 +0400 (EDT)", "POP")#<BR> <B>ParseDateTime("Sat, 15 Aug 1998 19:00:00 +0400"):</B> #ParseDateTime("Sat, 15 Aug 1998 19:00:00 +0400")#<BR> <B>ParseDateTime("Sat, 15 Aug 1998 19:00:00 +0400 (EDT):</B> #ParseDateTime("Sat, 15 Aug 1998 19:00:00 +0400 (EDT)", "Standard")#<BR> </CFOUTPUT>
Get Programming ColdFusion now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.