View helper for formatting dates.

category Zend
package Zend_I18n
subpackage View

 Methods

Format a date.

__invoke(\DateTime | integer | array $date, integer $dateType, integer $timeType, string $locale) : string

Parameters

$date

\DateTimeintegerarray

$dateType

integer

$timeType

integer

$locale

string

Exceptions

\Zend\I18n\Exception\RuntimeException

Returns

string

Get the timezone to use.

getTimezone() : string | null

Returns

stringnull

Get the view object

getView() : null | \Zend\View\Renderer\RendererInterface
Inherited

inherited_from \Zend\View\Helper\AbstractHelper::getView()

Returns

Get the locale to use.

getlocale() : string | null

Returns

stringnull

Set timezone to use instead of the default.

setTimezone(string $timezone) : \Zend\I18n\View\Helper\DateFormat

Parameters

$timezone

string

Returns

Set the View object

setView(\Zend\View\Renderer\RendererInterface $view) : \Zend\View\Helper\AbstractHelper
Inherited

inherited_from \Zend\View\Helper\AbstractHelper::setView()

Parameters

Returns

Set locale to use instead of the default.

setlocale(string $locale) : \Zend\I18n\View\Helper\DateFormat

Parameters

$locale

string

Returns

 Properties

 

Formatter instances.

$formatters : array

 

Locale to use instead of the default.

$locale : string

 

Timezone to use.

$timezone : string

 

View object

$view : \Zend\View\Renderer\RendererInterface
Inherited

inherited_from \Zend\View\Helper\AbstractHelper::$$view