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]

Dynamic Tables in FO


Okay, I have some XML code that represents a table structure syntax, much
the way it does in html.

However, I'm having problems generating the code to PDF. Here is a clip of
the XML:

<jncTable>
	<jncTableRow>
		<jncTableHeader>Item</jncTableHeader>
		<jncTableHeader>Naming Convention</jncTableHeader>
		<jncTableHeader>Example</jncTableHeader>
	</jncTableRow>
	<jncTableRow>
		<jncTableItem>Arguments/parameters</jncTableItem>
		<jncTableItem>Use a full English...</jncTableItem>
		<jncTableItem>customer, account- or -aCustomer,
anAccount</jncTableItem>
	</jncTableRow>
	<jncTableRow>
		<jncTableItem>Fields/fields/properties</jncTableItem>
		<jncTableItem>Use a full English...</jncTableItem>
		<jncTableItem>firstName, lastName, waprSpeed</jncTableItem>
	</jncTableRow>
</jncTable>


And here is the XSL I'm trying to get working:

<xsl:template match="jncTable" name="111">
<!-- debugging code -->
<fo:block font-size="99pt">here</fo:block>

<fo:block>
	<fo:table>
		<fo:table-column column-width="40mm"/>
		<fo:table-column column-width="100mm"/>
		<fo:table-column column-width="50mm"/>
		<fo:table-body>
			<xsl:for-each select="./jncTableRow">
				<fo:table-row>
					<!-- headers section... -->
					<xsl:for-each
select="./jncTableHeader">
						<fo:table-cell>
							<fo:block>
	
<xsl:value-of select="."/>
							</fo:block>
						</fo:table-cell>
					</xsl:for-each>
					<!-- ...headers section -->
				</fo:table-row>
				<fo:table-row>
					<!-- data section... -->
					<xsl:for-each
select="./jncTableItem">
						<fo:table-cell>
							<fo:block>
	
<xsl:value-of select="."/>
							</fo:block>
						</fo:table-cell>
					</xsl:for-each>
					<!-- ...data section -->
				</fo:table-row>
			</xsl:for-each>
		</fo:table-body>
	</fo:table>
</fo:block>

<!-- debugging code -->
<fo:block font-size="99pt">here</fo:block>
</xsl:template>

When executing the code through cocoon, I get both debug meesage on screen
but the table doesn't create.

Anyone able to help?

Cheers,
Anthony Ikeda,
Web Application Developer,
Proxima Technology,

Level 13,
181 Miller Street,
North Sydney
Australia


PH: +612-9458-1718
Mob: 041 624 5143


 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]