cfdocument error on total page count

72 views
Skip to first unread message

Giampiero Vaccari

unread,
Mar 10, 2017, 10:41:20 AM3/10/17
to Lucee
I'm porting some code from ACF 9 to Lucee 4.5.
I've found an issue in the output produced by cfdocument.
The cfdocument.totalpagecount is wrong as it is always equal to cfdocument.totalsectionpagecount.
Try to run the following test snippets in ACF9 and Lucee 4.5 and see the different results.
Any idea? 
Thanks

<cfdocument format="pdf">
<cfdocumentitem type="header" evalatprint="true">
    <table width="100%" border="0" cellpadding="0" cellspacing="0"> 
        <strong><tr><td align="right"><cfoutput>#cfdocument.currentsectionpagenumber# of</strong> 
            <strong>#cfdocument.totalsectionpagecount#</cfoutput></td></tr></strong> 
    </table> 
</cfdocumentitem> 
  
<cfdocumentitem type="footer" evalatprint="true">
    <table width="100%" border="0" cellpadding="0" cellspacing="0"> 
        <strong><tr><td align="center"><cfoutput>#cfdocument.currentpagenumber# of</strong> 
            <strong>#cfdocument.totalpagecount#</cfoutput></td></tr></strong> 
    </table> 
</cfdocumentitem> 
  
<cfdocumentsection>
    <h1>Section 1</h1> 
    <cfloop from=1 to=50 index="i">
        Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.<p> 
    </cfloop> 
</cfdocumentsection> 
  
<cfdocumentsection>
    <h1>Section 2</h1> 
    <cfloop from=1 to=50 index="i">
        Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.<p> 
    </cfloop> 
</cfdocumentsection> 
  
<cfdocumentsection>
<h1>Section 3</h1> 
    <cfloop from=1 to=50 index="i">
        Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.<p> 
    </cfloop> 
</cfdocumentsection> 
</cfdocument>

Zac Spitzer

unread,
Mar 15, 2017, 10:57:08 PM3/15/17
to lu...@googlegroups.com
does this still occur in the latest 5.1 build?

--
You received this message because you are subscribed to the Google Groups "Lucee" group.
To unsubscribe from this group and stop receiving emails from it, send an email to lucee+unsubscribe@googlegroups.com.
To post to this group, send email to lu...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/lucee/7c71493c-be08-4458-baee-5dde63b5c8aa%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Zac Spitzer
+61 405 847 168

Giampiero Vaccari

unread,
Mar 24, 2017, 6:52:39 AM3/24/17
to Lucee
I coul't try on 5.1. I've to work on 4.5. 
Is there any workaround?
To unsubscribe from this group and stop receiving emails from it, send an email to lucee+un...@googlegroups.com.

To post to this group, send email to lu...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/lucee/7c71493c-be08-4458-baee-5dde63b5c8aa%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages