You can use either getToken() or ListGetAt().
Say your date is a variable. Then set the date format how you want it.
Code:
<cfset thisDate = DateFormat(now(),'mm-dd-yyyy')>
This will display as "07-02-2009". Use the "-" as a delimiter.
Code:
<cfset thisMonth = getToken(thisDate,1,"-")>
<cfset thisMonth = ListGetAt(thisDate,1,"-")>
Both examples pretty much do the same thing. Get value in first position of a list that is delimited by a hyphen. Then do the same for day and year:
Code:
<cfset thisMonth = getToken(thisDate,1,"-")>
<cfset thisMonth = ListGetAt(thisDate,1,"-")>
<cfset thisDay = getToken(thisDate,2,"-")>
<cfset thisDay = ListGetAt(thisDate,2,"-")>
<cfset thisYear = getToken(thisDate,3,"-")>
<cfset thisYear = ListGetAt(thisDate,3,"-")>
^_^
Bookmarks