You are here

protected function DatexObject::createINTLFormatter in Datex 7.2

Create an IntlDateFormatter fot this object.

1 call to DatexObject::createINTLFormatter()
DatexObject::setUseINTL in datex_api/datex_api.class.inc
Set whether to use PHP-Intl or not.

File

datex_api/datex_api.class.inc, line 628
Provides an API to work with dates.

Class

DatexObject
Base class for localized DateTime.

Code

protected function createINTLFormatter($tz = NULL) {
  $args = $this->intlArgs;
  if (!$tz) {
    $tz = date_default_timezone_get();
  }
  $this->intlFormatter = new IntlDateFormatter($args[0], $args[1], $args[2], $this
    ->getTzString($tz), $args[3]);
}