<xsl:template name="DescT">
<xsl:variable name="desc">
<xsl:value-of select="@description"/>
</xsl:variable>
<xsl:variable name="descFormatted">
<xsl:choose>
<xsl:when test="contains($desc, 'References:')">
<xsl:value-of select="substring-before($desc, 'References:')"/>
<xsl:call-template name="RefT">
<xsl:with-param name="var" select="substring-after($desc, 'References:')"/>
</xsl:call-template>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="$desc"/>
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
<!-- Insert a carriage return and Remediation title between the first and second
paragraph in the description if there is one
-->
<xsl:choose>
<xsl:when test="contains($descFormatted,'
')">
<xsl:value-of select="concat(substring-before($descFormatted,'
'),'<br><br><B>Remediation: </B>',substring-after($descFormatted,'
'))"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="$descFormatted"/>
</xsl:otherwise>
</xsl:choose>
</xsl:template> |