Spec: Python XML templating language (PXTL)

Andrew Clover and@doxdesk.com
Mon, 10 Mar 2003 12:49:13 +0000

PXTL is a specification for a templating format mixing XML-based markup
languages with Python code. It is especially suitable for use in a web
application's page output stage.

*Another* web templating system? Yes, I'm afraid so. PXTL does have a few
features which are (as far as I know) unique, though:

  - it's a pure-XML format, which should make syntax and nesting errors
    very easy to debug (especially with a syntax-colouring, well-formedness
    checking text editor);
  - output can automatically be translated into legacy (non-XML) HTML or
    non-tag-based formats;
  - a number of XML processing instructions for including content in
    various common escaping formats;
  - elements from a separate namespace for flow-control (if, for, def, etc.),
    to allow a Python code hierarchy and XML markup hierarchy to be mixed

I'm pleased to announce the second draft of the PXTL specification, and I'd
appreciate any feedback on it from web and XML authors (in particular those
familiar with XHTML) either by mail or to c.l.py.


A reference implementation will be made available (under some manner of
open-source licence) some time in the next few months, taking into account
any comments received.


Andrew Clover