How can I put a page break into the PDF created by the Download PDF Datalist Action?

Confluence User - 05 Sep, 2020

Hello,

I have a form in which using the Download PDF Datalist Action I am creating a PDF of the form. I want to put a page break in that PDF. Is there a way to customize the PDF with the page-break? 

Thanks in advance,

Sebnem


pdf;page_break

2


06 Sep, 2020
confluenceUser
1
confluenceUser

It uses html to pdf conversion. You can google for the correct css / HTML coding to achieve that. Joget uses ITextRenderer.

See https://github.com/jogetworkflow/jw-community/blob/7.0-SNAPSHOT/wflow-core/src/main/java/org/joget/apps/form/service/FormPdfUtil.java#L118


Try

<div style="page-break-before: always; page-break-after: always; width: 100%; height: 500px; background-color: gainsboro; border: 2px solid gray; text-align: center">

inside your form → custom HTML to introduce the page break.

Reference: https://www.evopdf.com/demo/HTML_to_PDF/Page_Breaks/Insert_Page_Breaks_Before_After_Using_CSS.aspx

12 Sep, 2020
confluenceUser
confluenceUser

Thank you! It worked. I've used simply this line in the custom HTML :

<div style="page-break-before : always"></div>

RELATED QUESTIONS

Your answer


To answer a question you'll need an account.

Print