Skip to content

Instantly share code, notes, and snippets.

@dwcramer
Created December 4, 2012 00:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dwcramer/4199240 to your computer and use it in GitHub Desktop.
Save dwcramer/4199240 to your computer and use it in GitHub Desktop.
templates to create a revhistory table
<xsl:template match="processing-instruction('rax')[normalize-space(.) = 'revhistory']" mode="preprocess">
<xsl:if test="//d:revhistory[1]/d:revision">
<informaltable rules="all">
<col width="20%"/>
<col width="80%"/>
<thead>
<tr>
<td align="center">Revision Date</td>
<td align="center">Summary of Changes</td>
</tr>
</thead>
<tbody>
<xsl:apply-templates select="//d:revhistory[1]/d:revision" mode="revhistory"/>
</tbody>
</informaltable>
</xsl:if>
</xsl:template>
<xsl:template match="d:revision" mode="revhistory">
<tr>
<td valign="top">
<para>
<xsl:call-template name="shortDate">
<xsl:with-param name="in" select="d:date"/>
</xsl:call-template>
</para>
</td>
<td>
<xsl:copy-of select="d:revdescription/*"/>
</td>
</tr>
</xsl:template>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment