It seems logical to me that there would be an easy axis or something else to select the text of all siblings, including self, but I can't seem to find it.
XML:
<panelTabs>
<field></field>
<field></field>
</panelTabs>
I'm currently in a <xsl:template match="panelTabs/field>
, and I need to be in this template. I want to check whether or not all of the values within every <field>
are empty, How do I do this?
Edit:
To be a little more specific. I would like my XSLT to be something like this:
<xsl:template match="panelTabs/field>
<xsl:if test="allfieldshaventgottext = true">
<p>All are empty</p>
</xsl:if>
<xsl:if test="thereisafieldwithtext = true">
<p>There is a field with text</p>
</xsl:if>
</xsl:template>
Instead of an xsl:if
, an xsl:when
will do
No comments:
Post a Comment