The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

HTML::Template::Filter::TT2 - Template Toolkit 2 syntax for HTML::Template

VERSION

Version 0.02

SYNOPSIS

    use HTML::Template::Filter::TT2;

    my $tmpl = HTML::Template->new(filter => \&ht_tt2_filter, ...);

DESCRIPTION

This HTML::Template filter allows you to use the Template Toolkit 2 syntax, which is much less verbose than the default syntax. This is not an emulation of TT2, so you're still limited to the usual HTML::Template semantics. Also, in order to keep the filter fast and simple, the [% end %] must be written with the block name. See below for details.

Recognized syntax:

  • variables: [% variable %], [% variable :default |filter %]

  • if statements: [% if condition %] ... [% else %] ... [end_if %]

  • loops: [% loop loop-name %] ... [% end_loop %]

EXPORT

Exports the ht_tt2_filter function by default.

FUNCTIONS

ht_tt2_filter()

Pass a reference to this function to the filter parameter when calling <HTML::Template-new()>>

AUTHOR

Sébastien Aperghis-Tramoni, <sebastien at aperghis.net>

SEE ALSO

HTML::Template, Template::Toolkit

BUGS

Please report any bugs or feature requests to bug-html-template-filter-tt2 at rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=HTML-Template-Filter-TT2. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.

SUPPORT

You can find documentation for this module with the perldoc command.

    perldoc HTML::Template::Filter::TT2

You can also look for information at:

COPYRIGHT & LICENSE

Copyright 2007 Sébastien Aperghis-Tramoni, all rights reserved.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.