I have a document with an electronic stamp (E-Materai), set as SetSourceFile in the latest PHP MPDF library (version 8.2). After execution, the electronic stamp is not recognized (it doesn't appear as it does in the original document). The document itself is rendered perfectly.
Seeking guidance on how to address this issue and ensure proper rendering of the electronic stamp with MPDF 8.2.
Has anyone else encountered this issue, or do you have any other ideas to resolve this problem?
Here is the simple code that I implemented:
$mpdf = new \Mpdf\Mpdf();
$file_name = 'Document.pdf';
$pagecount = $mpdf->SetSourceFile($file_name);
for ($i=1; $i<=$pagecount; $i++) {
$import_page = $mpdf->ImportPage($i);
$size = $mpdf->getTemplateSize($import_page);
$mpdf->UseTemplate($import_page, 0, 0, $size['width'], $size['height'], true);
if ($i < $pagecount){
$mpdf->AddPage($size['orientation']);
}
}
$mpdf->Output('Draft Template Item _'. date('Ymd_His') .'.pdf', 'I');
Output Original File vs After Render with MPDF. Click Here to View
Previously, I was using MPDF version 8.0, and I assumed that after updating to the latest version, I could resolve this issue. However, it turns out that's not the case.
I hope the rendering results with MPDF will match the original file.