<!--- Match toes element. ---> <xsl:template match="//toes"> OPEN-TOES <!--- Apply template to all the toe nodes. ---> <xsl:apply-templates select="toe" /> CLOSE-TOES </xsl:template> <!--- Match toe element. ---> <xsl:template match="toe"> TOE </xsl:template>