Copy link to clipboard
Copied
Copy link to clipboard
Copied
Copy link to clipboard
Copied
yes the best way is to use dateformat function. this function takes two arguments the first the date it self, and the second is the date format. in your case for example we can use that function such:
<cfset month = #dateformat(now(), 'mm')#>the output will be 12 for decemeber
this will get you the numeric portion of the month; you can also get fancy with it and get the letters by adding another m such as:
<cfset month = #dateformat(now(), 'mmm')#>the output will be Dec for december.
also coldfusion is rich with other datetime functions that can make life super easy i hope that helped
Find more inspiration, events, and resources on the new Adobe Community
Explore Now