TAL as an “easy” Templating Language
Is TAL an alternatuve to XSLT which can be more easily edited, managed and understood by webmasters?
TAL has 2 advantages over XSLT:
- It’s less complex
- It can be edited by any HTML editor
The second point is interesting becaus TAL introduces no new tags. You just design your HTML page as per normal but add attributes which define where your content goes.
TAL Snippet:
<html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns="http://www.w3.org/1999/xhtml">
<head>
<title tal:content="document/header/title">Here comes the title</title>
</head>
<body>
…
</body></html></code>
The TAL template refers to content elements via XPATH expressions.
In order to avoid having to write a TAL parser we can use a transformation to convert the TAL template to XSLT. Some bright spark has created the tal2xslt.xsl for us so all we need is xmlstarlet or other XSLT processor and we can create our pages with the following easy batch file:
xml tr tal2xslt.xsl template.tal.html > template.xsl
xml tr template.xsl page1.xml > page1.html
del template.xsl
Now I need to find a way to process a complete site…

Dear Jack
I am researching CMS vendors, and I would like to know more about 1 Man CMS.
My organization is considering partnering with CMS vendor for some of the work we do, and I
would appreciate if you could email me
(a) the pricing range for your CMS,
(b) any additional promotional information or white papers which you think
would be useful for us to read, and which are not on your site.
Kind regards,
Amit Dey
amit@ideaedit.org
Comment by Amit dey — July 18, 2006 @ 7:39 pm