[geeklog-devtalk] Optimizing MySQL (was: SPAM Article)

Tony Bibbs tony at tonybibbs.com
Fri Mar 4 09:23:55 EST 2005


Michael Jervis wrote:


>

>

>

>>The problem is that once you decide on a template engine,

>>you're basically stuck with it ...

>>

>>

>

>Not necessarily true, it entirely depends on how you design your templating

>support. I've seen two alternative approaches to the one in geeklog which

>mean you can do exactly what you like.

>

>The first is to use an adapter pattern and abstract the template engine you

>use. Then you can swap out the template engine very easily.

>

>

I'd argue that no amount of abstraction here will make changing the
template engine easy in 1.3.x. The adapter simply gives you the clean
seperation. You'd still have a sh*tload of code to change/write if you
added support for another templates engine.

In GL2 we have abstract views (in the MVC sense) that build in support
for PEAR::HTML_Template_Flexy. We support that natively but if a plugin
wanted to use a different template engine (or two together which doesn't
make much sense) you could. I guess this just highlights the obvious
benefits of an oo-design.

--Tony



More information about the geeklog-devtalk mailing list