Zend Framework Source Code Snippets

Zend_Pdf Page Count

Bookmark and Share
1
2
3
4
foreach($pdf->pages As $key => $page)
{
        $page->drawText("Page " . ($key+1) . " of " . count($pdf->pages), $x, $y);                      
}

Comments

You must login before commenting on a snippet. If you do not have an account, please register.

Snippet description

Prints a page count on each page of a Zend_Pdf document. This must be run after all of the pages have been added to the document.

There may well be a better way of doing this built in to Zend_Pdf, but I am a maverick and have not read the documentation.

Snippet details

Created:
tharriso tharriso
1 year ago
Edited:
tharriso tharriso
1 year ago
Revision Id:
192
Edit Message:
Initial Release
ZF Version
1.10.7
Tags:
Zend_Pdf Pagination Page Count Pdf
Comments:
0
Views:
2346
Points:
0 (0 votes)

History

r192

Initial Release

tharriso tharriso
1 year ago
diff
r191

Initial Release

tharriso tharriso
1 year ago
diff
r190

Initial Release

tharriso tharriso
1 year ago