Skip to content
kerrishotts edited this page Nov 13, 2012 · 1 revision

(part of PKLOC)

Return Type: string

Parameters: theDate [, theFormat [, theLocale ] ]

Localizes a date according the user's current locale (or the given locale) based on the format specified. The format is based on the format rules specified here. If no format is specified, "d" is used instead.

For example:

__D( new Date(2012, 1, 20) )       ==>   2/20/2012
__D( new Date(2012, 1, 20), "D" )  ==>   Monday February 20th, 2012

Notes

The initializeGlobalization method must have been called prior to using this method, and the appropriate localization files need to have been loaded with loadLocales.

Version

0.1 Introduced

0.2 Docs Valid

Clone this wiki locally