Re: Please help generating a fo from a xml and xsl

You wrote:

> I need to generate a .fo file for FOP, here is a snippet i wrote by hand of
> part of my .fo file

Argh. Hand-written FO files. That's masochism!

The FO namespace is meant to be used with XSLT, which should do
what you need. You could have an input XML file such as:

<headers>
  <header>Client Details</header>
  <header>Contact Details And Numbers</header>
</headers>
      
and an XSL stylesheet:

<xsl:template match="headers">
  <fo:table-header font-family="ArialBold" font-size="10pt" >
    <fo:table-row >
      <xsl:apply-templates/>
    </fo:table-row>
  </fo:table-header>
</xsl:template>

<xsl:template match="header">
  <fo:table-cell border-style="solid" ...>
    <xsl:apply-templates/>
  </fo:table-cell>
</xsl:template>

Max.

Received on Friday, 16 November 2001 08:50:51 UTC