xmlgraphics-fop-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ricardo Soe-Agnie <R.Soe-Ag...@famed.nl>
Subject RE: need help with templating issues...
Date Fri, 10 Nov 2006 08:13:23 GMT
Sorry for that!, thanks for the solutions and I will keep that in mind next
time.

Cheers,
R.

-----Oorspronkelijk bericht-----
Van: Andreas L Delmelle [mailto:a_l.delmelle@pandora.be] 
Verzonden: donderdag 9 november 2006 21:42
Aan: fop-users@xmlgraphics.apache.org
Onderwerp: Re: need help with templating issues...

On Nov 9, 2006, at 16:13, Ricardo Soe-Agnie wrote:

Hi,

> I want to transform the following XML to PDF:

I see you're a first-time poster, but to us all it seems like the  
zillionth time:

Such questions actually do not belong on this list. Mulberry's XSLT  
list is much, much better suited. This list is meant for problems/ 
questions wrt using Apache FOP to transform FO into PDF. The XSL  
transform is a separate step, which has very little to do with FOP  
itself...

Please try to keep that in mind for the future. Thanks!

On that note, you'll also notice, if you browse the archives, that  
many of us can't resist to offer you an answer anyway, so here we go.

For the nodes for which there is no explicit matching template  
defined, the default template is invoked, which ultimately comes down  
to:

<xsl:template match="*">
   <xsl:apply-templates />
</xsl:template>

and thus for their text-node children:

<xsl:template match="text() | @*">
   <xsl:value-of select="." />
</xsl:template>


Two possible solutions:
- either define an empty template for the nodes you don't want to see  
processed, like so

   <xsl:template match="SendDate | TotalAmount | Debtor" />

- or apply-templates to only those nodes you do want to see appear in  
the result, so replace this one here
...
>       <fo:page-sequence master-reference="simpleA4">
>         <fo:flow flow-name="xsl-region-body">
>             <fo:block>
>               <xsl:apply-templates/>
                 ^^^^^^^^

with
   <xsl:apply-templates select="Reference | Creditor" />



HTH!

Cheers,

Andreas


---------------------------------------------------------------------
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


Mime
View raw message