<body>
<h3>LSDateFormat Example</h3>
<p>Format the date part of a date/time value using the locale convention.
<!--- loop through a list of locales; show date values for Now()--->
<cfloop list = "#Server.Coldfusion.SupportedLocales#"
index = "locale" delimiters = ",">
<cfset oldlocale = SetLocale(locale)>
<cfoutput><p><B><I>#locale#</I></B><br>
#LSDateFormat(Now(), "mmm-dd-yyyy")#<br>
#LSDateFormat(Now(), "mmmm d, yyyy")#<br>
#LSDateFormat(Now(), "mm/dd/yyyy")#<br>
#LSDateFormat(Now(), "d-mmm-yyyy")#<br>
#LSDateFormat(Now(), "ddd, mmmm dd, yyyy")#<br>
#LSDateFormat(Now(), "d/m/yy")#<br>
#LSDateFormat(Now())#<br>
<hr noshade>
</cfoutput>
</cfloop>
</body>
</html>
Additional globalization tags and functions
In addition to the tags and functions that are specifically for globalized applications, you might
find the following useful when writing a globalized application:
•
All string manipulation functions. For more information, see the String functions list in
Chapter 3, "ColdFusion Functions,"
•
The
GetTimeZoneInfo
Handling data in ColdFusion MX
Many of the issues involved with globalizing applications deal with processing data from the
various sources supported by ColdFusion MX, including the following:
•
General character encoding issues
•
Locale-specific values
•
URL strings
•
Forms
•
Files
•
Databases
•
E-mail
•
HTTP
•
LDAP
•
WDDX
•
COM
•
CORBA
•
Verity searches
This section describes how to handle data from each of these sources.
382
Chapter 17: Developing Globalized Applications
in CFML Reference.
function, which returns the time zone of the operating system.