,我有以下类型的XML文档输出:XSL:的 “嵌套” 结构
<item>
<item>
<item>
... (same elements <item> ... </item> here)
</item>
</item>
</item>
...及以下XSL变换:
<xsl:template match="item"><xsl:text>
open</xsl:text>
<xsl:apply-templates/><xsl:text>
close</xsl:text>
</xsl:template>
我得到的是:
open
open
open
close
close
close
所以我不知道是否有可能以某种方式得到一个输出与缩进像此:
open
open
open
close
close
close
感谢您的帮助!
P.S.通过让转换的输出方法为HTML,应该可以获得我想要的。但是,我需要在文本中“直接”缩进,而不是使用任何类型的HTML列表等。