The following functions can be called within HTML using [? funcname() ?] and from within PHP global scope. Most
PHP functions are also available.
Returns a formatted currency
Where the system currency is AUD and we just want to show the price formatCurrency(15) would simply render "$15.00 AUD"
Where system currency is AUD, and we want to show Approx.
NZD amount converts from AUD to NZD. formatCurrency(15, null, 'NZD') would render "Approx. $19.25 NZD"
Where system currency is AUD, and we want to show Approx. NZD amount when the amount is in EUR
Converts from EUR to AUD, then AUD to NZD formatCurrency(15, 'EUR', 'NZD') would render "Approx. $35.26 NZD "
Where system currency is AUD, and we want to display NZD amount
No conversion, just rendering. formatCurrency(15, 'NZD') would render "$15.00 NZD"
Parameters
float
$fPrice The price to be rendered
string|null
$strCurrencyId The currency code of $fPrice
string|null
$strCurrencyConvertId The currency code to convert to
bool
$bDisplayCurrencyId Whether or not to display the currency label - eg AUD
bool
$bDisplaySymbol Whether or not to display the currency sign - eg $