cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Christian Barth" <coc...@barth-zone.de>
Subject RE: XSL-Problem. I can't find the error
Date Mon, 16 Jan 2006 14:15:21 GMT

> -----Original Message-----
> From: Zsolt Czinkos [mailto:czinkos@interware.hu] 
> Sent: Monday, January 16, 2006 1:51 PM
> To: users@cocoon.apache.org
> Subject: Re: XSL-Problem. I can't find the error
> 
> Hello
> 
> I think this is an XSLT issue, not cocoon.
> 
> As far as I know, XSLT doesn't have "xsl:if - xsl:otherwise"
> construction. You should use xsl:choose instead:

You are right. That was the problem!

Thanks a lot,

Barthi

> 
> <xsl:choose>
>   <xsl:when test="$typ = 'A'"> (if your A is a string value)
>     ...
>   </xsl:when>
>   <xsl:when test="$typ = 'B'">
>     ...
>   </xsl:when>
>   <xsl:otherwise>
>     ...
>   </xsl:otherwise>
> </xsl:choose>
> 
> 
> Hopes, this helps.
> 
> Best regards,
> 
> czinkos
> 
> ps: i am new on this list, hello everyone. I am planning to 
> use cocoon as a framework for a userbased online desktop. :)
> 
> 
> On Mon, Jan 16, 2006 at 01:38:13PM +0100, Christian Barth wrote:
> > > -----Original Message-----
> > > From: Geert Josten [mailto:Geert.Josten@daidalos.nl]
> > > Sent: Monday, January 16, 2006 12:42 PM
> > > To: users@cocoon.apache.org
> > > Subject: Re: XSL-Problem. I can't find the error
> > > 
> > > Hi,
> > > 
> > > It is a bit confusing that you are referring to XSP pages as .xsl 
> > > files.
> > 
> > Well, that's right. Maybe I'll change it.
> > 
> > > Apart from that, your snippet looks okay on first impression. You 
> > > are passing {request-param:typ} as a map:parameter to the 
> relevant 
> > > map:transforms, as far as I can see just from glancing at 
> it. I do 
> > > notice that you are using xinclude. Are you performing 
> HTTP requests 
> > > to Cocoon internally with Xinclude? If so, pass the query 
> string on 
> > > to it
> > 
> > That was the step I had forgotten. Now I have the parameter 
> in the xsl-file.
> > But fo rany reason, the if-Clause isn't executed. Could you please 
> > have a look again?
> > 
> > Here is the code:
> > 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
> 
> 

Mime
View raw message