Dear List,

   I have a variable given in Cents and I want to print it out in 
Dollars. I know that I can write a filter routine in Perl but I would
prefer to do it all in the template. I tried this:

[%- USE format -%]
[%- dollars = format('%.2f') -%]
...
[% dollars(amount/100) %]

but obviously the "amount/100" is not allowed as the argument to 
dollars(). What's a good way to do it?

Bye
Frederik
 
-- 
Frederik Ramm  ##  eMail [EMAIL PROTECTED]

_______________________________________________
templates mailing list
[email protected]
http://lists.template-toolkit.org/mailman/listinfo/templates

Reply via email to