Re: template module
| From: | Stig S. Bakken | Date: | Fri, 03 Aug 2001 07:01:35 +0000 |
| Subject: | Re: template module | ||
| References: | 1 2 3 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-1265@lists.php.net to get a copy of this message | ||
Graeme Merrall wrote:
>
> Quoting "Stig S. Bakken" <ssb@alltheweb.com>:
>
> > Nice idea. But this also means that the common template functionality
> > needs a common API. Is that doable (I'm not familiar enough with
> > IT[X]
> > and Smarty to tell)?
>
> It's not an entirely silly idea. Jesus Castagnetto wrote a template cache class
> that interfaced to 6 or so different templates classes.
> There's no reason that a template class can't have a set of adaptors to
> communicate via a common API although I imagine Smarty is different enough not
> to fit that mould.
>
> It would be an interesting exercise to answer a lot of the 'more than 1
> template class' argument.
It'd basically be a template engine abstraction layer. I suggest using
the top-level "Template" namespace for it, since template systems are
not limited to HTML.
- Stig