RE: [xsl] problem endless rekursion

Subject: RE: [xsl] problem endless rekursion
From: Jarno.Elovirta@xxxxxxxxx
Date: Thu, 6 Nov 2003 10:50:51 +0200
Hi,

> can you please help me with the following problem.
> the problem is to check a check box question. the correct 
> cells and the
> false cells should be added. the result are the correct 
> cells. there is a endless
> rekursion?????
> 
[snip]
> 
> <xsl:template match="option" mode="check">
>   <xsl:variable name="correct_cells" select=".
> |following-sibling::solution[valid_input = 1]" />

The problem is with these two variables. The current node is contained in the node-set bound to the variable and you apply the template for it, thus the infinite recursion. Also, the expressions here are not valid against the source document you showed, they should be

  following-sibling::option/solution[@valid_input = 1]

I couldn't really understand the logic of your stylesheet—could you show us the desired output?

Cheers,

Jarno - some Melotron track, can't remember which

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread