diff options
author | Edmund von der Burg <evdb@mysociety.org> | 2011-02-23 13:58:27 +0000 |
---|---|---|
committer | Edmund von der Burg <evdb@mysociety.org> | 2011-02-23 13:58:27 +0000 |
commit | 1498dfdec73becf769c3596bf41185f003c2a4cf (patch) | |
tree | ecd6b5d780ad74cede79493a960b3cad4ad0480e /perllib/FixMyStreet/App/View/Web.pm | |
parent | 684ae4edc50c66617abe369233005770192d8170 (diff) |
Added About controller
put 'loc' stub in place for i18n in templates
server static files
Diffstat (limited to 'perllib/FixMyStreet/App/View/Web.pm')
-rw-r--r-- | perllib/FixMyStreet/App/View/Web.pm | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/perllib/FixMyStreet/App/View/Web.pm b/perllib/FixMyStreet/App/View/Web.pm index a201242bc..dcda54db9 100644 --- a/perllib/FixMyStreet/App/View/Web.pm +++ b/perllib/FixMyStreet/App/View/Web.pm @@ -11,7 +11,8 @@ __PACKAGE__->config( INCLUDE_PATH => [ # FixMyStreet::App->path_to( 'templates', 'web', 'default' ), ], - render_die => 1, + render_die => 1, + expose_methods => ['loc'], ); =head1 NAME @@ -24,4 +25,20 @@ TT View for FixMyStreet::App. =cut +=head2 loc + + [% loc('Some text to localize') %] + +Passes the text to the localisation engine for translations. + +FIXME - currently just passes through. + +=cut + +sub loc { + my ( $self, $c, @args ) = @_; + return join ' ', @args; +} + 1; + |