MagicSmoke  $VERSION$
LanguageManager Class Reference

Public Member Functions

 formatDate ($date, $format)
 returns a date in current language formatted to the given format string More...
 
 formatFloatNumber ($num, $digits=2, $flags=0)
 format a float number More...
 
 formatIntNumber ($num, $flags=0)
 format an integer number More...
 
 getDate ($date)
 returns date in current language, default: ISO-date More...
 
 getDateTime ($date)
 returns date in current language, default: ISO-date More...
 
 getPrice ($price, $flags=3)
 returns price in current language More...
 
 getTime ($time)
 returns time in current language More...
 
 getValue ($key)
 returns value for specified key in current language More...
 
 templateFolder ()
 returns the configured language template folder More...
 
 templateFolders ()
 returns the configured language template folder plus its fallback More...
 

Static Public Member Functions

static getLanguages ()
 returns all supported languages More...
 
static resetLanguage ($lang)
 resets the singleton instance to a different language More...
 
static setLanguage ()
 checks parameters, sets a language cookie returns home More...
 
static singleton ()
 returns the instance of the Language Manager More...
 

Public Attributes

const MoneyCurrencyClient =0x20
 show the clients (Unicode) version of the currency symbol More...
 
const MoneyCurrencyHTML =0
 show the HTML version of the currency symbol More...
 
const MoneyCurrencyMask =0xf0
 mask for currency symbol choice More...
 
const MoneyCurrencyPlain =0x10
 show the plain ASCII version of the currency symbol More...
 
const MoneyShowCurrency =2
 show the currency symbol More...
 
const UseThousandSeparator =1
 show the thoursand separator in numbers and money More...
 

Member Function Documentation

LanguageManager::formatDate (   $date,
  $format 
)

returns a date in current language formatted to the given format string

References $d, $date, and $i.

Referenced by getDate(), getDateTime(), and getTime().

LanguageManager::formatFloatNumber (   $num,
  $digits = 2,
  $flags = 0 
)

format a float number

References $i, and formatIntNumber().

Referenced by getPrice().

LanguageManager::formatIntNumber (   $num,
  $flags = 0 
)

format an integer number

References $i.

Referenced by formatFloatNumber().

LanguageManager::getDate (   $date)

returns date in current language, default: ISO-date

References $date, and formatDate().

LanguageManager::getDateTime (   $date)

returns date in current language, default: ISO-date

References $date, and formatDate().

static LanguageManager::getLanguages ( )
static

returns all supported languages

References $d, and $template.

LanguageManager::getTime (   $time)

returns time in current language

References formatDate().

LanguageManager::getValue (   $key)

returns value for specified key in current language

static LanguageManager::resetLanguage (   $lang)
static

resets the singleton instance to a different language

static LanguageManager::setLanguage ( )
static

checks parameters, sets a language cookie returns home

References $HTTPARGS, COOKIE_LANGUAGE, and redirectHome().

static LanguageManager::singleton ( )
static

returns the instance of the Language Manager

References $default_language.

Referenced by LangFilterExtension\__construct(), SmokeFilterExtension\__construct(), and i18n().

LanguageManager::templateFolder ( )

returns the configured language template folder

Referenced by templateFolders().

LanguageManager::templateFolders ( )

returns the configured language template folder plus its fallback

References $default_language, and templateFolder().

Member Data Documentation

const LanguageManager::MoneyCurrencyClient =0x20

show the clients (Unicode) version of the currency symbol

Referenced by LangFilterExtension\getPriceClient().

const LanguageManager::MoneyCurrencyHTML =0

show the HTML version of the currency symbol

Referenced by LangFilterExtension\getPriceHtml().

const LanguageManager::MoneyCurrencyMask =0xf0

mask for currency symbol choice

const LanguageManager::MoneyCurrencyPlain =0x10

show the plain ASCII version of the currency symbol

Referenced by LangFilterExtension\getPricePlain().

const LanguageManager::MoneyShowCurrency =2
const LanguageManager::UseThousandSeparator =1

show the thoursand separator in numbers and money

Referenced by LangFilterExtension\getPriceClient(), LangFilterExtension\getPriceHtml(), and LangFilterExtension\getPricePlain().


The documentation for this class was generated from the following file: