[Catalyst-commits] r12323 - in trunk/examples/SmallBoard:
lib/SmallBoard/View root root/src
dhoss at dev.catalyst.perl.org
dhoss at dev.catalyst.perl.org
Sun Dec 13 00:27:00 GMT 2009
Author: dhoss
Date: 2009-12-13 00:26:59 +0000 (Sun, 13 Dec 2009)
New Revision: 12323
Added:
trunk/examples/SmallBoard/root/src/
trunk/examples/SmallBoard/root/src/index.tt2
trunk/examples/SmallBoard/root/src/wrapper
Modified:
trunk/examples/SmallBoard/lib/SmallBoard/View/TT.pm
Log:
tweaked view settings and added some wrapper shit
Modified: trunk/examples/SmallBoard/lib/SmallBoard/View/TT.pm
===================================================================
--- trunk/examples/SmallBoard/lib/SmallBoard/View/TT.pm 2009-12-13 00:20:09 UTC (rev 12322)
+++ trunk/examples/SmallBoard/lib/SmallBoard/View/TT.pm 2009-12-13 00:26:59 UTC (rev 12323)
@@ -6,8 +6,11 @@
use base 'Catalyst::View::TT';
__PACKAGE__->config(
- TEMPLATE_EXTENSION => '.tt2',
- WRAPPER => 'root/wrapper',
+ TEMPLATE_EXTENSION => '.tt2',
+ INCLUDE_PATH => [
+ SmallBoard->path_to( 'root', 'src' ),
+ ],
+ WRAPPER => 'wrapper',
);
=head1 NAME
Added: trunk/examples/SmallBoard/root/src/index.tt2
===================================================================
--- trunk/examples/SmallBoard/root/src/index.tt2 (rev 0)
+++ trunk/examples/SmallBoard/root/src/index.tt2 2009-12-13 00:26:59 UTC (rev 12323)
@@ -0,0 +1 @@
+<h2>SMALLBOARD IS SMALL</h2>
Added: trunk/examples/SmallBoard/root/src/wrapper
===================================================================
--- trunk/examples/SmallBoard/root/src/wrapper (rev 0)
+++ trunk/examples/SmallBoard/root/src/wrapper 2009-12-13 00:26:59 UTC (rev 12323)
@@ -0,0 +1,13 @@
+[% IF template.name.match('\.(css|js|txt)') || no_wrapper;
+ debug("Passing page through as text: $template.name");
+ content;
+ ELSE %]
+ <!DOCTYPE html>
+ <html>
+ <head>
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
+ <title>[% title || "SMALLBOARD" %]</title>
+ </head>
+ <body>[% content %]</body>
+ </html>
+[% END %]
More information about the Catalyst-commits
mailing list