View helper for formatting currency.
Methods
__construct()
__construct()
Format a number
__invoke(float $number, string $currencyCode, bool $showDecimals, string $locale, string $pattern) : string
Parameters
$number
float
$currencyCode
string
$showDecimals
bool
$locale
string
$pattern
string
Returns
string
Get the 3-letter ISO 4217 currency code indicating the currency to use
getCurrencyCode() : string
Get the currency pattern
getCurrencyPattern() : string
Get the locale to use
getLocale() : string | null
Set the View object
setView(\Zend\View\Renderer\RendererInterface $view) : \Zend\View\Helper\AbstractHelper
Inherited
inherited_from |
\Zend\View\Helper\AbstractHelper::setView() |
Parameters
Returns
Get if the view helper should show two decimals
shouldShowDecimals() : bool
Properties
The 3-letter ISO 4217 currency code indicating the currency to use
$currencyCode : string
Currency pattern
$currencyPattern : string
Locale to use instead of the default
$locale : string
If set to true, the currency will be returned with two decimals
$showDecimals : bool