madison.sacd has asked for the wisdom of the Perl Monks concerning the following question:
Dear Monks,
I am trying to show different title in template.
In my controller list.pm, I assign a type variable to the template.
I am trying to show different title in template.
In my controller list.pm, I assign a type variable to the template.
In the template, according to the type, the metadata "title" will be assigned different value, "Book" or "CD". My problem is that I got correct debug output for each condition. However, "CD" will always be assigned to the metadata "title". In other words, when I pass type 'B' to template, the debug output shows "!!!!!!!!!!", which is correct, but the title displays "CD". Anything wrong with my code?$c->stash->{type} = 'B';
[% IF type == 'B'; META title = 'Book'; debug("!!!!!!!!!!"); debug(type); ELSE; debug("@@@@@@@@@@"); debug(type); META title = 'CD'; END; -%]
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: template toolkit question -- metadata
by Tomte (Priest) on May 11, 2007 at 08:27 UTC | |
A reply falls below the community's threshold of quality. You may see it by logging in. |
Back to
Seekers of Perl Wisdom