Bob Faist > Mojolicious-Plugin-HTMLTemplateRenderer-0.04 > Mojolicious::Plugin::HTMLTemplateRenderer

Download:
Mojolicious-Plugin-HTMLTemplateRenderer-0.04.tar.gz

Dependencies

Annotate this POD

CPAN RT

New  1
Open  0
View/Report Bugs
Module Version: 0.04   Source  

NAME ^

Mojolicious::Plugin::HTMLTemplateRenderer - Mojolicious Plugin

SYNOPSIS ^

  # Mojolicious
  $self->plugin('HTMLTemplateRenderer');


  # Mojolicious::Lite
  plugin 'HTMLTemplateRenderer';

  # Render HTML::Template handler and post 'utf8 => 1' option for next HTML::Template->new call
  get '/' => sub{
    my $self = shift;
    $self->render('bender', handler => 'tmpl', tmpl_new_opts => {utf8 => 1});
  }


  # Set default options for all HTML::Template->new calls
  plugin 'HTMLTemplateRenderer', tmpl_new_opts => {blind_cache => 1, open_mode => '<:encoding(UTF-16)'};

DESCRIPTION ^

Mojolicious::Plugin::HTMLTemplateRenderer is a Mojolicious plugin.

METHODS ^

Mojolicious::Plugin::HTMLTemplateRenderer inherits all methods from Mojolicious::Plugin and implements the following new ones.

register

  $plugin->register;

Register plugin in Mojolicious application.

SEE ALSO ^

Mojolicious, Mojolicious::Guides, http://mojolicio.us.

COPYRIGHT & LICENSE ^

Copyright 2011 Bob Faist, all rights reserved.

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

syntax highlighting: