Package: collective - PageTemplateTransformer
a test of SfIndex product
Sourceforge Info
| Project Name: | collective |
| Package Name: | PageTemplateTransformer |
| Files Page: | |
| Browse CVS: | http://cvs.sourceforge.net/viewcvs.py/collective/PageTemplateTransformer/ |
Package README (CVS ver. 1.1.1.1)
$Id: readme.txt,v 1.1.1.1 2004/06/08 15:45:33 zopezen Exp $
Copyright: Enfold Systems Ltd
License: http://www.enfoldsystems.com
Ever got annoyed at a page template in Plone that has one thing different from
the way you want? You could change that page template by customising it, but
then when it changes in Plone you are out of date.
What you need is PageTemplateTransformer. It alters PageTemplates on the fly
using XML to the format you want. This allows you to just change the one bit
you want. For example for ZopeZen I wanted descriptions in searches to show
HTML. This would mean changing the whole template. Instead I just patched that
one dd in the search.pt file with one line of code. As long as that dd remains,
that code will always be up to date. (see tests for an example of this).
Install:
Copy into your Plone products directory
Usage:
See new ZopeZen skin for some examples
To do:
After writing it a few things became clear:
- this could probably just be done with xslt :)
- the config file for the patches should be in plain text, not python
- this is pretty neat but still a bit of work