This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

RE: Selectively displaying numbers



Mickey Bradshaw has done all the hard work:

<xsl:choose>
     <xsl:when test="@lineID mod 5 = 0">
     <td>
          <xsl:value-of select="@lineID"/>
     </td>
     </xsl:when>
     <xsl:otherwise>
     <td></td>
     </xsl:otherwise>
<xsl:choose>


As a minor enhancement, if your table has borders or a
background, you may consider inserting a non-breaking
space (&#160;) when you do not output a line number:

<xsl:choose>
     <xsl:when test="@lineID mod 5 = 0">
     <td>
          <xsl:value-of select="@lineID"/>
     </td>
     </xsl:when>
     <xsl:otherwise>
     <td>&#160;</td>
     </xsl:otherwise>
<xsl:choose>

Martin



 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]