Pregunta

Im still working with flying saucer to export xhtml to pdf.

At the moment its just a datatable with header and footer on every page.

The problem is, the header on the second page (and also on the following ones) has no margins, so the header underlays the content of the datatable, because the table is too large for one page.

Ive tried a lot, but nothing works.

The margins are set with css style in the body tag.

Hope somebody can help me as far.

Greetings

¿Fue útil?

Solución

Solved it to my own:

Just added

@page { margin: 100px 50px 50px}

to the styles.

The table had a very bad looking break after a page, so I added also this:

tr{page-break-inside:avoid;}

Now it works fine.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top