<?xml version="1.0" encoding="ISO-8859-1"?>
<!--
Make code to generate the document object
Also included HEADER and FOOTER on this file
-->
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xsl:template name="MAKE_DOCUMENT">
// this is the customized document object for this report
class PHPRepoDoc_ extends PHPRepoDoc {
// don't print nothing here
function getFormattedRow() {
}
// prints customized header for this document object
function printHeader( $oValue ) {
$header = $oValue; // nice way to refer to header data ;-)
<xsl:if test="count(/REPORT/DOCUMENT/HEADER)>0">
<xsl:text>print "<table </xsl:text>
<xsl:apply-templates select="/REPORT/DOCUMENT/HEADER"/>
<xsl:text>>"; </xsl:text>
<xsl:call-template name="MAKE_DOC_HEADER"/>
<xsl:text>				print "</table>"; </xsl:text>
<xsl:text>				print "<br clear='all'/><br/>"; </xsl:text>
<!-- <xsl:text>				print "<p class='breakhere'></p>";</xsl:text> //-->
</xsl:if>
<xsl:text> 			} </xsl:text>
// prints customized footer for this document object
function printFooter( $oValue ) {
<xsl:if test="count(/REPORT/DOCUMENT/FOOTER)>0">
<xsl:text>print "<table </xsl:text>
<xsl:apply-templates select="/REPORT/DOCUMENT/FOOTER"/>
<xsl:text>>"; </xsl:text>
<xsl:call-template name="MAKE_DOC_FOOTER"/>
<xsl:text>				print "</table>"; </xsl:text>
<xsl:text>				print "<br clear='all'/><br/>"; </xsl:text>
<!-- <xsl:text>				print "<p class='breakhere'></p>";</xsl:text> //-->
</xsl:if>
<xsl:text> 			} 		} </xsl:text>
</xsl:template>
<!--
Document header
-->
<xsl:template name="MAKE_DOC_HEADER">
<xsl:for-each select="/REPORT/DOCUMENT/HEADER/ROW">
<xsl:text>				print "<tr>"; </xsl:text>
<xsl:for-each select="COL">
<xsl:call-template name="MAKE_COL"/>
</xsl:for-each>
<xsl:text>	print "</tr>"; </xsl:text>
</xsl:for-each>
</xsl:template>
<!--
Document footer
-->
<xsl:template name="MAKE_DOC_FOOTER">
<xsl:for-each select="/REPORT/DOCUMENT/FOOTER/ROW">
<xsl:text>				print "<tr>"; </xsl:text>
<xsl:for-each select="COL">
<xsl:call-template name="MAKE_COL"/>
</xsl:for-each>
<xsl:text>	print "</tr>"; </xsl:text>
</xsl:for-each>
</xsl:template>
</xsl:stylesheet>
|