I have a currency value that I would like to format using Locale::Currency::Format
however I have no idea how to format it.
Here is my output in Template Toolkit
[% amount %]
I would like this to be outputted using the following method:
currency_format('USD', amount, FMT_SYMBOL)
New to template toolkit so any help is appreciated.
I like Dave Cross' answer, and I agree with both he and codnodder about
EVAL_PERL
, which I've yet to find necessary as a solution in 7 or 8 years of almost daily TT use.Personally, I would use:
But if I was using this all the time, I'd be tempted to write a TT plugin wrapper around it.