[Home] [By Thread] [By Date] [Recent Entries]
At 06:27 PM 6/20/01, Jeni wrote:
Hi Dennis.... If you're producing text, on the other hand, then the easiest way to achieve the indentation is to pass down a 'indent' parameter from template to template.... Another easiest way is to use our good friend, the much-maligned but faithful xsl:for-each, as in <xsl:template match="group">
<xsl:for-each select="ancestor::group">
<xsl:text> </xsl:text>
</xsl:for-each>
<xsl:text>GROUP-LEVEL
<xsl:text>
<xsl:apply-templates/>
</xsl:template>and do the same in the template matching "field" to get them indented too. (Put the for-each in a named template if you have to use it alot.) This would work, wouldn't it Jeni? It's kind of a refinement of the count(ancestor::*) technique. Cheers, Wendell
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|

Cart



