You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-users@xmlgraphics.apache.org by Danelaw <da...@gmail.com> on 2009/10/15 10:14:39 UTC
Using fop to generate csv
Hello i am new to fop formatting :S and i need help with page formatting .....
i want to put values from an xml into csv in text mode .... the
problem i am having is that when i generate the simple example of
hello world i get a "full page" of text full of white lines, how can i
remove this white lines? i only need to have the file with no pages no
margins etc ..... all text in the same file with my own breaks.
any help or suggestion to see examples will be helpfully
many thx to all
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
Re: Using fop to generate csv
Posted by Danelaw <da...@gmail.com>.
but i need the same method for both systems .... i only want to change
the Driver.RENDER_PDF to Driver.RENDER_TEXT
but you are true .... i only need the transformation, perhaps i need
to change all the method and not the form of formatting it.
thx for the example
On Thu, Oct 15, 2009 at 11:40 AM, ruud grosmann <r....@gmail.com> wrote:
> a short example:
>
> INPUT
> <?xml version="1.0" encoding="UTF-8"?>
> <woordenlijst>
> <titel>zelfstandige naamwoorden, v1.0</titel>
> <term>
> <spaans> abreviatura, la</spaans>
> <nederlands>afkorting </nederlands>
> </term>
> <term>
> <spaans>abrigo, el</spaans>
> <nederlands>jas, bescherming</nederlands>
> </term>
> </woordenlijst>
>
> XSLT STYLE SHEET
> <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
> version="2.0">
>
> <xsl:output method='text'/>
>
> <xsl:template match="/woordenlijst">
> <xsl:apply-templates select="term"/>
> </xsl:template>
>
> <xsl:template match="term">
> <xsl:value-of select='normalize-space(spaans)'/>
> <xsl:text>;</xsl:text>
> <xsl:value-of select='normalize-space(nederlands)'/>
> <xsl:text>
> </xsl:text>
> </xsl:template>
>
> </xsl:stylesheet>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
Re: Using fop to generate csv
Posted by ruud grosmann <r....@gmail.com>.
a short example:
INPUT
<?xml version="1.0" encoding="UTF-8"?>
<woordenlijst>
<titel>zelfstandige naamwoorden, v1.0</titel>
<term>
<spaans> abreviatura, la</spaans>
<nederlands>afkorting </nederlands>
</term>
<term>
<spaans>abrigo, el</spaans>
<nederlands>jas, bescherming</nederlands>
</term>
</woordenlijst>
XSLT STYLE SHEET
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="2.0">
<xsl:output method='text'/>
<xsl:template match="/woordenlijst">
<xsl:apply-templates select="term"/>
</xsl:template>
<xsl:template match="term">
<xsl:value-of select='normalize-space(spaans)'/>
<xsl:text>;</xsl:text>
<xsl:value-of select='normalize-space(nederlands)'/>
<xsl:text>
</xsl:text>
</xsl:template>
</xsl:stylesheet>
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
Re: Using fop to generate csv
Posted by ruud grosmann <r....@gmail.com>.
On 15/10/2009, Danelaw <da...@gmail.com> wrote:
> Hello i am new to fop formatting :S and i need help with page formatting
> .....
>
> i want to put values from an xml into csv in text mode ....
Hi,
it sounds to me you don't need fop at all, but only xslt. Or do you
plan to make an pdf file with the csv lines?
If the answer is 'no', stick to your xslt style sheet.
regards, Ruud
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org