xslt 2.0 - match uncaught though declared in XSL -


i've below xml.

<para indent="no">    <star.page>18</star.page> further same. </para> 

and when run below xslt.

<xsl:template match="para">      <xsl:value-of select="./node()[1][self::star.page]|./label/node()[1][self::star.page]"/>     <div>         <xsl:choose>             <xsl:when test="./@align">                 <xsl:attribute name="class"><xsl:text>para align-</xsl:text><xsl:value-of select="./@align"/></xsl:attribute>             </xsl:when>             <xsl:otherwise>                 <xsl:attribute name="class"><xsl:text>para</xsl:text></xsl:attribute>             </xsl:otherwise>         </xsl:choose>         <xsl:apply-templates/>     </div> </xsl:template> 

when run this, instead of printing <div class="para">18</div>, printing <div class="para"></div>

please let me know going wrong , how can fix this.

thanks


Comments

Popular posts from this blog

matlab - "Contour not rendered for non-finite ZData" -

delphi - Indy UDP Read Contents of Adata -

javascript - Any ideas when Firefox is likely to implement lengthAdjust and textLength? -