[Catalyst] HOWTO reference config settings from template

Bill Moseley moseley at hank.org
Fri Apr 13 02:58:29 GMT 2007

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).

Bill Moseley
moseley at hank.org

More information about the Catalyst mailing list