Details
Assignee
Michael OffnerMichael OffnerReporter
Brad WoodBrad WoodLabels
New Issue warning screen
Before you create a new Issue, please post to the mailing list first https://dev.lucee.org
Once the issue has been verified, one of the Lucee team will ask you to file an issue
Priority
New
Details
Details
Assignee
Michael Offner
Michael OffnerReporter
Brad Wood
Brad WoodLabels
New Issue warning screen
Before you create a new Issue, please post to the mailing list first https://dev.lucee.org
Once the issue has been verified, one of the Lucee team will ask you to file an issue
Priority
Created 26 August 2021 at 21:06
Updated 3 September 2021 at 15:48
Take the simple PDF at the bottom. On Adobe ColdFusion, the page numbers are correctly
1/3
2/3
3/3
But on Lucee they are
1/1
1/1
1/1
on each page UNLESS you add evalatprint="true" to at least the header or footer.
According to Adobe's docs
Therefore, it should be possible to know the before-print page numbers.
Even an explicit
<cfdocumentitem type = "pagebreak"/>
inside the loop does not trick Lucee into counting the pages. Note, an explicit page break WILL work correctly with no document sections.
<cfdocument format="PDF"> <cfoutput> <cfloop from="1" to="3" index="i"> <cfdocumentsection> <cfdocumentitem type="header"> Header #cfdocument.currentpagenumber# / #cfdocument.totalpagecount# </cfdocumentitem> page content <cfdocumentitem type="footer"> footer #cfdocument.currentpagenumber# / #cfdocument.totalpagecount# </cfdocumentitem> </cfdocumentsection> </cfloop> </cfoutput> </cfdocument>