Forum Bugs

Combining documents

I'm combining multiple short html documents on the command line to a single PDF file, each using the same CSS styles for headers and footers. The footer contains the page number in addition to a background colour and other text. The headers and contents are rendered fine in the PDF, but I only get the footer on the first page - the other pages have a blank space where the footer should be.

The way I would expect combining multiple documents to work is that each document is rendered as a self-contained unit and combined into a single document with page numbers and facing (left or right) being passed from one document to the next.

The most obvious way to do this would be to have additional command line options to set initial values for page numbering and facing, so the user can control this output themselves. Specifying multiple documents to assemble would have the effect of passing the numbering and facing from one document to the next.
That sounds like a bug; headers and footers should still apply to all the documents.
Hi, just a quick note that this bug is still present in the current (6.0r3) release.
Thanks, I've added it to the roadmap for the next release.
Hi Mike, I've done some further experimentation with the page numbering. I am combining several short xhtml documents (1-2 pages each) together with a "front matter" document which contains a cover page and a table of contents.

Each of the documents, including the front matter document, is based on a standard template which defines header, content and footer sections. The header and footer divs are diverted into the @top and @bottom margins through the use of named flows.

The first problem I had was that my footer didn't appear until the last page of any individual document - because the contents of the footer div aren't read until the end of the document. The solution to that was to use:
flow: static(header, start)

to apply it back to the beginning of the document. Unfortunately, when combining multiple documents, this results in the footer only appearing on the first page.

If I remove the "start" argument and combine the documents I get correct page numbering, but with the footer only on the last page of each of the original documents.

If I move the footer definitions in the source documents to appear before the content definitions, all footers appear correctly.

I have another page numbering issue, but I'll put it in another post. :)
This should be fixed in Prince 6.0 rev 4, out today. Thanks for reporting the issue! :)
Hi Prince,
Here I have a scenario to take a pdf with multiple html strings with different page behavior in my .net project.
I mean, we have two or more html string. Each html string may have different behavior in the style of them (eg: each html string may be different margin, page orientation, font size, etc).

So, I want to get a single pdf using the byte array that combines or merges each of the html string.
And we want to see the pdf based on the all html string with the style behavior of each html string.

I attached a example view here.
Based on the example view. The upper document(“A”) is a landscape view and the page margin is 40px and the second document(“B”) is a portrait view and the page margin is 22px. Both the documents are in a single pdf file without breaking the behavior of each html string or document.

Could you please help me on how could I achieve this scenario using .net wrapper?

  1. multipledocuments.png67.6 kB
    Example view