Commit 503e956e by Mohammad Izzat Johari

refactor

parent dbd13614
......@@ -464,6 +464,9 @@ class Pkcs11Command
$orientation = ($size['width'] > $size['height']) ? 'L' : 'P';
$fpdi->AddPage($orientation, [$size['width'], $size['height']]);
// put watermark in front the content
$fpdi->useTemplate($tplIdx, 0, 0, $size['width'], $size['height']);
// 🔹 Draw watermark first (goes behind)
$fpdi->SetFont('Helvetica', '', 10);
$fpdi->SetTextColor(200, 200, 200); // very light gray
......@@ -481,7 +484,8 @@ class Pkcs11Command
}
// 🔹 Now place the original page content on top
$fpdi->useTemplate($tplIdx, 0, 0, $size['width'], $size['height']);
// put watermark in back the content
// $fpdi->useTemplate($tplIdx, 0, 0, $size['width'], $size['height']);
}
// Output to string (S = string)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment