mPDF Manual – mPDF Variables

pagenumSuffix

(mPDF >= 3.0)

Description

string pagenumSuffix

Specify text to follow the page number when using {PAGENO} to insert page numbers in headers or footers.

Examples

Example #1

<?php

$mpdf = new mPDF();

$mpdf->pagenumPrefix = 'Page number ';

$mpdf->pagenumSuffix = ' - ';

$mpdf->nbpgPrefix = ' out of ';

$mpdf->nbpgSuffix = ' pages';

$mpdf->SetHeader('{PAGENO}{nbpg}');

$mpdf->WriteHTML("Hallo World");

$mpdf->Output();

?>
Will output a header:

"Page number 1 - out of 1 pages"

See Also