On Tue, 2005-01-18 at 16:08, Uri Guttman wrote:
> templating is not rocket science. that is why there
> are so many template modules on cpan. they are trivial to do basic
> versions. whether they mature into large systems like tt2 is another
> matter.
True, but the advantage of having a baseline way of templating (and this
is the BIG advantage of PHP) is that you can then abstract away from
that and develop second-derivative toolsets. This is what TTK has done
(look at the number of Template::* modules in CPAN that aren't part of
the core Template-Toolkit).
When you roll your own, you have to stop and think about how and if to
integrate each of these new tools, and I always find myself limiting the
scope of a project instead of tackling that kind of battle.
Some examples for TTK:
Template::Plugin::Translit::RU
Template::Plugin::Tooltip
Template::Plugin::Textile
Template::Plugin::TextToHtml
Template::Plugin::TagRescue
Template::Plugin::Table
Template::Plugin::StringTree
Template::Plugin::StickyQuery
Template::Plugin::Stash
Template::Plugin::Siesta
Template::Plugin::Shuffle
Template::Plugin::ShellQuote
Template::Plugin::Session
Those are just the Ss and Ts!
Mason too has a fair number of extensions (though fewer, I think, than
TTK).
> AS> This is the way content and code should be combined... anything more
> AS> complex than the above should be used to construct the variables.
>
> please restate that last sentence in english. i think we are agreeing
> but i can't be for sure! :)
"This is the way content and code should be combined (that is, by using
variables in simple HTML, with as little flow control as possible)...
anything (that is, code) more complex than the above (simple example)
should be used to construct the variables (in, say, Perl which are then
used by the templating system to search/replace the template)."
Or another way of saying that is:
Your templates should never have a complex boundary between code and
content.
Is that better? And, yes, I think we're agreeing on that point from the
gate.
--
â 781-324-3772
â [EMAIL PROTECTED]
â http://www.ajs.com/~ajs
_______________________________________________
Boston-pm mailing list
[email protected]
http://mail.pm.org/mailman/listinfo/boston-pm