HTML::Template::Compiled::Plugin::Comma - HTC Plugin to commify numbers
use HTML::Template::Compiled::Plugin::Comma; my $htc = HTML::Template::Compiled->new( plugin => [qw(HTML::Template::Compiled::Plugin::Comma)], ... ); $htc->param( costs => 10000 ); $htc->output; --- This item costs <TMPL_VAR costs ESCAPE=COMMA> dollar. # Output: # This item costs 10,000 dollar.
HTML::Template::Compiled::Plugin::Comma is a plugin for HTC, which allows you to commify your numbers in templates. This would be especially useful for prices.
register gets called by HTC
HTML::Template::Compiled, "perldoc -q comma"
HTML::Template::Compiled
hagy
Copyright (C) 2007 by hagy
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.6 or, at your option, any later version of Perl 5 you may have available.
To install HTML::Template::Compiled::Plugin::Comma, copy and paste the appropriate command in to your terminal.
cpanm
cpanm HTML::Template::Compiled::Plugin::Comma
CPAN shell
perl -MCPAN -e shell install HTML::Template::Compiled::Plugin::Comma
For more information on module installation, please visit the detailed CPAN module installation guide.