|
Posted by Ted Zlatanov on March 26, 2008, 5:39 pm
Please log in for more thread options
On Wed, 26 Mar 2008 09:50:51 -0700 merlyn@stonehenge.com (Randal L. Schwartz)
wrote:
RLS> The theory is that by having a simpler template language, you get
RLS> two benefits:
RLS> You don't have to explain @a vs $a to a web designer, and yet they
RLS> can probably pick up the simpler templating language to edit their own
RLS> templates for common cases.
RLS> If it's starts getting difficult to write in the mini-language, it
RLS> probably means it should have been factored out into model or controller
RLS> code (that is, it's not view code any more).
RLS> This comes from lots of experience with TT.
To append from my own experience...
I've tried templates for web designers, using:
- Mason
- Template Toolkit
- invented syntax (supposedly simpler)
- Javacript-interpreted templates
Eventually the designer has to program with any of them, and some
designers just aren't good at programming. I find it easier to ask the
designer to create an example, convert it into the template toolkit of
choice (with all the loops, conditionals, etc.), and then let the
designer iterate the template further while *carefully* supervising them
to make sure they don't screw it up.
Ted
|