XSDDateFormat(str_date)
Last updated March 18, 2002
Version: 1 | Requires: ColdFusion 5 | Library: DateLib
Description:
Takes an Date/Time and makes it into simple XSD date time format (for use in xml xsds). Doesn't do time zones.
Return Values:
Returns a string.
Example:
The current date/time in XSD format is: #XSDDateFormat(now())#
</CFOUTPUT>
Parameters:
| Name | Description | Required |
|---|---|---|
| str_date | Date/time you want converted to XSD format. | Yes |
Full UDF Source:
<cfscript>
/**
* Takes an Date/Time and makes it into XSD time format (for use in xml xsds)
*
* @param str_date Date/time you want converted to XSD format.
* @return Returns a string.
* @author Rob (r2) (rob@rtwo.net)
* @version 1, March 18, 2002
*/
function XSDDateFormat(str_date){
return DateFormat(str_date,"yyyy-mm-ddT") & TimeFormat(str_date,"HH:mm:ss");
}
</cfscript>
Search CFLib.org
Latest Additions
Shawn Porter added
DeMoronize
3 hour(s) ago
Chris Carey added
readPropertiesFi...
1 day(s) ago
Randy Johnson added
lastDayofWeek
3 day(s) ago
Frank Marion added
sitemapPing
7 day(s) ago
Top Rated
QuickSort
Rated 5.0, 3 time(s)
indentXml
Rated 5.0, 3 time(s)
queryColumnsToSt...
Rated 5.0, 3 time(s)
generateSsccAsn
Rated 5.0, 3 time(s)