Hello group,

I try to do the following:

I want to label my file folders.

My xml looks like this:

<collection>
<folder id="1">
<top>University</top>
<middle>WBS</middle>
<middle>XML</middle>
<middle>XSL</middle>
<bottom>2003</bottom>
</folder>
<folder id="2">
<top>Insurance</top>
<middle>Barmenia</middle>
<middle>LVM</middle>
<middle>HUK</middle>
<middle>ADAC</middle>
<bottom>2003</bottom>
</folder>
...
</collection>

I have A4 sized paper. I have 1 to n folders. I would like to have a table that creates 1 to n columns. Then it should have 3 rows. In the first row <xsl:value-of select="top"/> - the main topic.
The second row <xsl:value-of select="middle"/> - subtopic.
The last row <xsl:value-of select="bottom"/> - year.


The problem that I (assume to) have, is that I only can use the <xsl:for-each select="//folder"> only once.

On the one hand I have to tell that there are 1 to n
<fo:table-column column-width="3cm"/>

On the other hand I have the 3 rows in 1 to n columns (example bottom)
<fo:table-row>
<fo:table-cell>
<fo:block text-align="center" padding-before="12cm" font-size="10" font-weight="bold">
<xsl:value-of select="bottom"/>
</fo:block>
</fo:table-cell>


I haven't figure out how to put 1 to n columns to a page and still display the content of top, middle, bottom , so here is a snip that each folder will have his own table.

I hope you understand what I am trying to do!

Thanks for any hints.

Example folder2fo.xsl:
<fo:block>
<xsl:for-each select="//folder">
<fo:table width="3cm" height="29,7cm" border-color="black" border-style="fixed">
<fo:table-column column-width="3cm"/>
<fo:table-header/>
<fo:table-body>
<fo:table-row>
<fo:table-cell>
<fo:block padding-top="2cm" text-align="center" font-size="16" font-weight="bold">
<xsl:value-of select="top"/>
</fo:block>
</fo:table-cell>
</fo:table-row>
<fo:table-row>
<fo:table-cell>
<fo:block text-align="center" padding-before="10cm" font-size="10" font-weight="bold">
<xsl:for-each select="middle">
<fo:block padding-before="24pt">
<xsl:value-of select="."/>
</fo:block>
</xsl:for-each>
</fo:block>
</fo:table-cell>
</fo:table-row>
<fo:table-row>
<fo:table-cell>
<fo:block text-align="center" padding-before="12cm" font-size="10" font-weight="bold">
<xsl:value-of select="bottom"/>
</fo:block>
</fo:table-cell>
</fo:table-row>
</fo:table-body>
</fo:table>
</xsl:for-each>
</fo:block>



--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to