错误mPDF需要mb_string函数.确保在启用php_mbstring.dll的情况下编译PHP?
码:
require_once("../mpdf/mpdf.php");
ob_start();
$template = ob_get_contents();
$template=$html;
ob_end_clean();
$mpdf=new mPDF();
$mpdf->WriteHTML($template);
$root = $_SERVER['DOCUMENT_ROOT'];
//$mpdf->Output($root.'/Dockets/'.$md5docketid.'.pdf', 'F');
//$mpdf->Output('C:\\'.$md5docketid.'.pdf', 'F');
$root = $_SERVER['DOCUMENT_ROOT'];
//echo $root;
$mpdf->Output($root.'/Dockets/'.$md5docketid.'.pdf', 'F');
解决方法:
尝试这个…
if (!function_exists(“mb_check_encoding”)) {
die(‘mbstring extension is not enabled’); }