Adjustment for restricting html components when rendering PDF

This commit is contained in:
David Bomba 2023-09-07 20:57:04 +10:00
parent 65f70e8d79
commit db37b50e21

View File

@ -39,6 +39,8 @@ trait PdfMaker
$pdf->addChromiumArguments(config('ninja.snappdf_chromium_arguments'));
}
$html = str_replace(['file:/', 'iframe', '&lt;object', '<object', '127.0.0.1', 'localhost'], ['','','','','',''], $html);
$generated = $pdf
->setHtml($html)
->generate();