changeset 17:0ad456dbb4c5

illustrate genshi transformer
author Jeff Hammel <jhammel@mozilla.com>
date Sun, 26 Sep 2010 16:03:33 -0700
parents 946176949bba
children 7800c6553c77
files example.ini example/hello.html
diffstat 2 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/example.ini
+++ b/example.ini
@@ -15,9 +15,9 @@ port = 6666
 use = egg:Paste#urlmap
 / = contenttransformer
 
 set debug = false
 
 [app:contenttransformer]
 paste.app_factory = contenttransformer.factory:factory
 transformer.directory = %(here)s/example
-transformer.transforms = *.gv.txt=Graphviz,*.txt=ReST,foo=text/plain
\ No newline at end of file
+transformer.transforms = *.gv.txt=Graphviz,*.txt=ReST,foo=text/plain,*.html=Genshi
\ No newline at end of file
--- a/example/hello.html
+++ b/example/hello.html
@@ -1,5 +1,5 @@
 <html xmlns="http://www.w3.org/1999/xhtml"
       xmlns:py="http://genshi.edgewall.org/"
       py:strip="True">
-Hello, world
-</html>
\ No newline at end of file
+Hello, ${request.GET.get('name')}
+</html>