I'm working on a xslt and xsl-fo code to convert to html and pdf respectively.
In my source xml I have a table which I can copy directly for html output.
<text>
<table border='1'>
<thead>
<tr><th>Problem</th><th>Date</th><th>Comments</th>
</tr>
</thead>
<tbody>
<tr>
<td>Cholecystitis</td><td>9/28/2002 - 6/2003</td>
<td>Resolved</td>
<td>Surgery postponed until after delivery</td>
</tr>
<tr>
<td>Pregnancy</td><td>7/2001 - 4/22/2002</td>
<td>Resolved</td>
<td>Prior history of miscarraige</td>
</tr>
<tr><td>Ankle Sprain</td><td>3/28/2005</td>
<td>Current</td>
<td>Slipped on ice and fell</td>
</tr>
</tbody>
</table>
</text>
I just use this to copy the content for node:
<xsl:copy-of select="."/>
I suppose this works for the xslt convertion to html since the browser can interpret this directly. But for my pdf I suppose I have to use xsl-fo which is completely different. I know in xsl-fo I have to use:
<fo:table>
But, is there a "standard" way to format this table to be able to use it for my pdf generation? The xsl:copy for the pdf produces a single line with all the stripped values but no table.
Thank you!
=====================================
EDIT
What I'm trying to do is to code some xslt to "parse" the table embeded in my source xml files to generate something like this:
<fo:table table-layout="fixed" width="100%">
<fo:table-column column-width="25mm"/>
<fo:table-column column-width="25mm"/>
<fo:table-body>
<fo:table-row>
<fo:table-cell>
<fo:block>
something
</fo:block>
</fo:table-cell>
</fo:table-row>
<fo:table-row>
<fo:table-cell>
<fo:block>
something
</fo:block>
</fo:table-cell>
</fo:table-row>
</fo:table-body>
</fo:table>
Is it the way to go?! Tables are pretty standard, I thought html table could be easily transformed to xslt/xsl-fo.