locale.name

From Inspired-Lua Wiki
Jump to: navigation, search

locale.name is a function that is part of the Locale Library.

This returns the name of the current locale. It normally returns a two-letter language code, but in some cases it also contains a two-letter country code (ISO-639).

For instance: en, fr, it, de, es, nl, nl_BE, en_GB

Syntax[edit]

locale.name()

(No arguments)

Example[edit]

currentLang = locale.name() --Puts the current locale name in currentLang