php - Spipu HTML2PDF not render UTF-8 font (khmer language) -
i try generate pdf both english , khmer font, render of khmer font "?" instead.
try { $html2pdf = new html2pdf("p", "a4", "en", true, "utf-8", [0, 0, 0, 0]); $html2pdf->pdf->setdisplaymode("fullpage"); ob_start(); include "property_pdf.pdf"; $content = ob_get_clean(); $html2pdf->writehtml($content); error_reporting(0); $html2pdf->createindex("", 30, 12, false, true, 1); $html2pdf->output("sample.pdf"); } catch (html2pdfexception $e) { $formatter = new exceptionformatter($e); echo $formatter->gethtmlmessage(); }
Comments
Post a Comment