currency
Summary
Fetches a currency object.Usage
fetch( 'shop', 'currency', hash( 'code', code ) )
Parameters
Name | Type | Description | Required |
---|---|---|---|
code | string | The three-character code of the target currency. | Yes. |
Returns
An ezcurrencydata object or FALSE.
Description
This function fetches the currency specified by the "code" parameter and returns it as an ezcurrencydata object. The function will return FALSE if the specified currency is unavailable.
Examples
Example 1
{def $code = 'EUR'} {def $currency = fetch( 'shop', 'currency', hash( 'code', $code ) )} {if $currency} The currency symbol for EUR is {$currency.symbol}. <br /> {/if}
Outputs the currency symbol that is used for the "EUR" currency if available.
Svitlana Shatokhina (05/05/2006 9:37 am)
Svitlana Shatokhina (11/01/2007 9:42 am)
Comments
There are no comments.