phpgroupware-developers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Phpgroupware-developers] TemplateEngine Question/Proposal


From: Ralf Becker
Subject: Re: [Phpgroupware-developers] TemplateEngine Question/Proposal
Date: Mon, 04 Aug 2003 09:48:58 +0200
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; de-AT; rv:1.4) Gecko/20030624

Kai Hofmann schrieb:
Hi Dave,


I took a deeper look into the TemplateEngine(s) and found:

Which branch?


HEAD

For HEAD it is planed to not longer use the phplib-like template engine. I necessary requirement is, that the used template engine delivers its content to the main xslt-engine.

each of these classes seems to be another modified version of an older (and buggy) version of the phplibs excelent template engine. The bug of this old phplib template engine is that it can not handle blocks within blocks correctly.

Our version seems to handle this ok. The version in phpgw is a modified version of the phplib tpl engine, as are our db classes.

for what are the modifications are required?
I think it might be better to stay by the original, because only in this
way you will get updates without problems.
About which version are you talking? I would like to verify it.


and also use it for xml - because there
is no
difference if
this template engine modifies html or xml.

How would you merge the changes? as there are quite a modifications in
the class.
>
simple use the original template engine from within the xslttemplate engine
and only add the transformation code there. This is much better than copy/paste
and modify
a perfectly working engine.
I have not looked at the new xslt tpl engine, but afaik it has extra
functionality to do the tranformations.

The XSLT engine has *nothing* to do with the phplib-like engine, beside for an easier transsiton, some function share the common name: eg. set_var().

Thats ok, but there is still no requirement (from my point of view) to
copy/paste the code
and modify it. It would be better to first use the phplib template engine to
fill in values
into an xml template, handle blocks etc. and then in a second step xsl
transform the resulting
xml document. So xslttemplate is for me another abstraction layer ontop of
the existing template engine.

That's not the way the XSLT engine works:
- you deliver the content as xml or a php-array
- you name one or more xslt-templates
- Sablotron processes them to eg. HTML
That means the phplib-templates are not used in that process and it would and it makes no sense at all to use them with XSLT (beside maybe proting an existing non-phpgw app).

Ralf
--
----------------------------------------------------------------------
Ralf Becker
OUTDOOR UNLIMITED Training GmbH                Telefon 0631 / 31657-0
Leibnizstraße 17                               Telefax 0631 / 31657-26
D-67663 Kaiserslautern            EMail address@hidden





reply via email to

[Prev in Thread] Current Thread [Next in Thread]