http://qs1969.pair.com?node_id=496633


in reply to Alternate template syntax for HTML::Template?

If you like asp/jsp-style tags you could consider HTML::Template::Compiled which is, as nice sideeffect, about 3 times faster than the original HTML::Template. If you want templates that are valid xml/xhtml you can take a look at Petal, which is an implementation of Zopes TAL for Perl.
  • Comment on Re: Alternate template syntax for HTML::Template?

Replies are listed 'Best First'.
Re^2: Alternate template syntax for HTML::Template?
by skx (Parson) on Oct 02, 2005 at 10:51 UTC

    Note that HTML::Template::Compiled isn't 100% compatible with HTML::Template.

    For example the following snippet of code shows errors:

    <tmpl_if name="title"> <title><!-- tmpl_var name="title" --></title> <tmpl_else> <title><!-- tmpl_var name='site_slogan' --></title> </tmpl_if>

    The error given references the second line:

    'TMPL_ELSE' does not match opening tag (if) at templates/index.templat +e line 2
    Steve
    --
      Note that HTML::Template::Compiled isn't 100% compatible with HTML::Template.

      For example the following snippet of code shows errors:

      thanks for pointing that out.
      i would still call it quite compatible (although not 100%, you're right), the above is just a bug. i'll try to repair it.

      update: fixed it, will be available soon on sourceforge.

        Wow - fast support!

        I first noticed this a few months ago, and forgot about it. Just testing my site today after being reminded of the modules existance was enough to see the problem again.

        I guess I've learned a good lesson today: I should report bugs when I first spot them instead of just dropping the modules!

        Steve
        --