OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help



   Re: [xml-dev] performant templating language for XML

[ Lists Home | Date Index | Thread Index ]

David Megginson wrote:
> On Tue, 28 Dec 2004 15:03:32 -0800, Nathan Young <natyoung@cisco.com> wrote:
>>I'm going to ask the following question:  Is there a good templating
>>language that can be used to build a high demand website from a collection
>>of XML documents?
> You can try JSP (Java Server Pages).  There is an alternative,
> XML-conformant syntax that works starting with version 1.1 or 1.2, and
> they allow for live content in the pages.  Unfortunately, it's a
> Java-only solution.  Recent versions of Tomcat support the XML JSP
> syntax, and at least some standard tagsets (like JSTL) work with it.


If using JSP, you will probably want to use version 2.0 if you can 
(Tomcat 5+, Resin 3+). This allows an Expression Lanuguage (EL) where 
you can do:

<a href="go?id=${id}"/>

as opposed to:

<a href="go?id=<%=id%>"/>

Annoyingly, most (all?) of frameworks/taglibs encourage something like:

<input type="submit" value="<tl:i18n key="global.submit"/>"/>

Another problem with JSP and its XML syntax is that containers implement 
it differently in small, but annoying ways. An example of a difference 
is creating an XHTML BR element (outputting contentType=text/xml). 
Tomcat will give you <br/>, but Resin will give you <br></br> which is a 
problem in IE.

And hardly anyone creates well-formed JSPs. I only do it when I (our 
CMS) generate them using XSL. If I am writing a JSP by hand I don't 
create a well-formed JSP XML.


> All the best,
> David


News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS