我正在使用 cfdocument
创建一个多页文档(使用动态文本创建,因此可以有任意数量的页面,甚至一页)。
我可以用 <cfdocumentitem type="footer">
为每一页添加页脚,但有什么办法只能在文档的最后一页添加页脚?
谢谢。
最佳答案
只需添加 evalAtPrint 属性。然后您可以使用页码变量有条件地设置页脚。
<cfdocumentitem type="footer" evalAtPrint="true">
<cfif cfdocument.currentPageNumber eq cfdocument.totalPageCount>
This is the last page
</cfif>
</cfdocumentitem>
关于coldfusion - 使用 cfdocument 时只在最后一页添加页脚,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4795207/