Page 1 of 1

Help for multiple page sequences within the single document

Posted: Wed Oct 25, 2006 4:37 pm
by Zarko
Hello everyone,

I am pretty new to xsl-fo and fop, so I would appreciate a little help.

We have an application that generates multiple reports as a single document using apache fop 0.20.5.
Every single report within this document should have pagination in form of

Code: Select all

<fo:page-number/>/<fo:page-number-citation ref-id="lastPage>
in its static content.
My problem is that there cannot be more than one ref-id with same name in a single document, and final result should be a single document with multiple page sequences like:1/3, 2/3, 3/3, 1/4, 2/4, 3/4, etc...

Is there any solution to this problem???

Posted: Mon Oct 30, 2006 3:36 pm
by sorin_ristache
Hello,

What do you mean there cannot be more than one ref-id with same name in a single document ? That is the purpose of the ref-id attribute, to refer the same id attribute from different locations of the XSL-FO document. The value of the id attribute must be unique in the document, that is you have to use an id attribute for the last page of each report included in your XSL-FO document:

Code: Select all

<fo:block id="lastPageReport1" text-align="center" ...>
and then refer it from each page of that report:

Code: Select all

<fo:page-number/> / <fo:page-number-citation ref-id="lastPageReport1"/>

Regards,
Sorin