I have a page with a folder and links inside
-FirstPage
+folder
-page
-page
-folder
-link1
-link2
-link3
-page
I want to reach the link1,link2,link3 in the tree. My current page is FirstPage. How do I do that?? This is the xsl i wrote and he give me the first link in the top folder
<xsl:template match="/">
<xsl:for-each select="$currentPage/descendant-or-self::* [@isDoc][@level=2]">
<xsl:if test="count(current()/descendant::* [@isDoc]) > 0">
<xsl:variable name="descendantPage" select="current()/descendant::* [@isDoc]"/>
<xsl:value-of select="$descendantPage/text"/>
</xsl:if>
</xsl:for-each>
</xsl:template>
Thank you for your help.
edit:new xsl I use...
<xsl:variable name="fId" select="number(1395)" />
<xsl:variable name="linksFolder" select="$currentPage/descendant-or-self::* [@isDoc][@level=2][@id='$fId']">
<xsl:template match="/">
<xsl:for-each select="$linksFolder/* [@isDoc]">
<xsl:value-of select="./text">
</xsl:for-each>
</xsl:template>
How can i avoid to use a output (like the id of the folder) to get the folder i want to? Thanks for your help...