This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Beginner XSL question


using the count()-function:

<xsl:template match="school">
   <xsl:value-of select="count(student)"/>
</xsl:template>

Joerg

Arturo C schrieb:
> Hi and sorry my english... how can i count the number of elements, for 
> instance, student in the following case:
> 
> <school>
>   <student>
>      ....
>   </student>
>   <student>
>      ....
>   </student>
>   <student>
>      ....
>   </student>
> </school>
> 
> and show the result (3) in an HTML page using XSL?
> 
> Thanks in advance!!
> 
> Arturo


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]