[Catalyst] HOWTO reference config settings from template
jchimene at gmail.com
Fri Apr 13 17:34:23 GMT 2007
Bill Moseley wrote:
> On Thu, Apr 12, 2007 at 04:18:06PM -0700, Jeff Chimene wrote:
>> Thanks for the reply. The problem I'm trying to solve is referencing
>> (reading) config settings from a template. I'd like to tell one or more
>> templates that sometimes they will use frames & sometimes not
>> (debugging). I blithely assumed this would be an appropriate use of
>> configuration variables. I was wrong. I'll use the stash for now.
> What's View is generating your templates?
> you can't do [% c.config.foo %] ?
> How about:
> [% USE Dumper; Dumper.dump( c.config ) | stderr %]
> Maybe your View isn't stuffing $c into the stash, or is using a
> different name (see C::View::TT).
Thanks for your reply. As I indicated in an earlier message
I've tried Dumper. I certainly get c.config values, but none of them are
TT2 configuration settings. I'm using a view generated by the catalyst
As a result of a PEK answer, I'm going to use the [% DEFAULT %]
directive in the root/lib/site/html file to address this particular
issue. As noted earlier "... stash variables are accessible is because
they are all that are provided to TT by default..." 
More information about the Catalyst