Name

LSParseDateTime

Synopsis

                  LSParseDateTime(datestring)

Returns a locale-specific ColdFusion date/time object from datestring. LSParseDateTime( ) is similar to the ParseDateTime( ) function except it doesn’t handle POP dates. If the supplied datestring contains a time zone, and it is different than the time zone of the ColdFusion server, the datestring is converted to the time zone of the ColdFusion server. Example:

<cfloop index="locale" list="#Server.Coldfusion.SupportedLocales#">
  <cfset SetLocale(locale)>
  <cfoutput>
    <p><b>#locale#</b><br>
    #LSParseDateTime("#LSDateFormat(Now( ))# #LSTimeFormat(Now( ))#")#<br> 
  </cfoutput>
</cfloop>

Get Programming ColdFusion MX, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.