cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joerg Heinicke <>
Subject Re: [heads up] [cforms] fi:styling/@type="output" ignored on widg ets with datatype=date.
Date Thu, 13 May 2004 18:40:04 GMT
On 13.05.2004 09:48, Sylvain Wallez wrote:

> <xsl:template match="fi:field[not(fi:styling/@type)]">
>  <xsl:choose>
>    <xsl:when test="fi:datatype[@type='date']">
>      ... calendar popup ...
>    </xsl:when>
>    <xsl:otherwise>
>      <xsl:apply-imports/>
>    </xsl:otherwise>
>  </xsl:choose>
> </xsl:template>
> OOP inheritance applied to XSLT!

I chose the old template selection style by complicating the matching 
pattern. It makes no real difference whether adding xsl:when test inside 
or changing the matching pattern.

But I had an ICQ session yesterday with Claas Thiele about JSF/Cocoon 
render manager/kit stuff. At the end it is obvious IMO: the cforms 
stylesheets simply miss a separation of renderer selection and rendering 
itself. At the moment we put the template selection into the match 
patterns and the rendering into the templates. The match patterns can 
therefore become complicated fast. If we put parts of the template 
selection into the template as it is done in the above sample it might 
get even worse - despite OOP inheritance. The render manager solves this 
by selecting the renderers - even directory based similar to the i18n 
transformer selecting the catalogue to use.


View raw message