For a few days I've been trying to generate a PDF report with PHP, I found several examples on the internet and everyone gives the same error, I've put the sample code and error print below.
My Xampp server is using PHP version 7 and the library to generate the PDF is mpdf60.
<?php
include("mpdf60/mpdf.php");
$html = "
<fieldset>
<h1>Teste de relatório</h1>
<div class='creditos'>
<p>Relatório pdf</p>
</div>
";
$mpdf=new mPDF();
$mpdf->SetDisplayMode('fullpage');
// $css = file_get_contents("css/estilo.css");
$mpdf->WriteHTML($css,1);
$mpdf->WriteHTML($html);
$mpdf->Output();
exit;
?>
See the error output:
Multiple libraries generate this error. If anyone can suggest another option. My project is simple does not use any framework.