Re: [xsl] Problem:Counting specific type of nodes lying in between two nodes in a tree

Subject: Re: [xsl] Problem:Counting specific type of nodes lying in between two nodes in a tree
From: Sanjukta Mitra <sanmit27@xxxxxxxxx>
Date: Mon, 7 Feb 2005 09:03:32 -0800 (PST)
Thanks a tonne Joris.With your help, the code is now
working.I'll take the cue on the element names too.
Regards
Sanjukta
--- Joris Gillis <roac@xxxxxxxxxx> wrote:

> Tempore 16:03:59, die 02/07/2005 AD, hinc in  
> xsl-list@xxxxxxxxxxxxxxxxxxxxxx scripsit Sanjukta
> Mitra  
> <sanmit27@xxxxxxxxx>:
> 
> >   If the current node is ptr6 this should return 4
> > Herebs the piece of code that is not working:
> >
> > <xsl:param name="Cnt"
> >
>
select="count(ancestor::decisiontree_answer[@answer='no'][ancestor::decisiontree_question[.=$stop_question]>
> > 0])"/>
> 
> Hi,
> 
> Try this code:
> <xsl:param name="Cnt"  
>
select="count(ancestor::decisiontree_answer[@answer='no'][ancestor::decisiontree_question=$stop_question])"/>
> 
> Btw, why are those element names so long? The root
> element is named  
> 'decisiontree', so why actually repeat that string
> over and over again?
> 
> 
> regards,
> -- 
> Joris Gillis
>
(http://www.ticalc.org/cgi-bin/acct-view.cgi?userid=38041)
> "In the land of the blind, the one-eyed man is king"
> 
> 



		
__________________________________ 
Do you Yahoo!? 
All your favorites on one personal page  Try My Yahoo!
http://my.yahoo.com 

Current Thread