Whatever message this page gives is out now! Go check it out!
DateConvert(conversionType, date)Parameter | Description |
conversionType |
|
date | Date and time string or a variable that contains one. To create, use CreateDateTime. |
You can pass the CreateDate or Now function as the date parameter of this function. For example, cfscript> writeoutput(DateConvert('local2utc',CreateDate(2019, 4, 10))) </cfscript> |
<cfscript>
// convert local date-time to UTC
utc_datetime = DateConvert('local2Utc', now());
writeOutput(utc_datetime & "<br/>")
// convert UTC date-time to local
local_datetime=DateConvert('utc2Local',now())
writeOutput(local_datetime)
</cfscript>