This version of the documentation is outdated!
Click here for the latest released version.
Globalization
The globalization
object obtains information and performs operations specific to the user's locale and timezone.
Objects
Methods
- globalization.getPreferredLanguage
- globalization.getLocaleName
- globalization.dateToString
- globalization.stringToDate
- globalization.getDatePattern
- globalization.getDateNames
- globalization.isDayLightSavingsTime
- globalization.getFirstDayOfWeek
- globalization.numberToString
- globalization.stringToNumber
- globalization.getNumberPattern
- globalization.getCurrencyPattern
Variable Scope
The globalization
object is a child of the navigator
object, and therefore has global scope.
// The global globalization object
var globalization = navigator.globalization;
Permissions
Android
app/res/xml/config.xml
<plugin name="Globalization" value="org.apache.cordova.Globalization" />