Skip to content

Instantly share code, notes, and snippets.

@thecfguy
Created February 29, 2016 11:09
Show Gist options
  • Save thecfguy/7839e1b566d2e60316d7 to your computer and use it in GitHub Desktop.
Save thecfguy/7839e1b566d2e60316d7 to your computer and use it in GitHub Desktop.
<cfscript>
rc.date = "Mon Feb 29 2016 00:00:00 GMT+0530 (IST)";
rc.date1 = DateAdd("s", 0, rc.date);
WriteDump(var=rc); //Converted to {ts '2016-02-28 22:00:00'} instead of {ts '2016-02-28 18:30:00'}
rc.date = "Mon Feb 29 2016 00:00:00 GMT+0430 (AFT)";
rc.date1 = DateAdd("s", 0, rc.date);
WriteDump(var=rc);
</cfscript>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment