Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error mPDF requires mb_string functions

Error mPDF requires mb_string functions. Ensure that PHP is compiled with php_mbstring.dll enabled ????

Code:

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');
like image 238
Noman Baig Avatar asked Jul 31 '26 09:07

Noman Baig


1 Answers

Try this...

if (!function_exists("mb_check_encoding")) { die('mbstring extension is not enabled'); }

like image 137
Abdul Moiz Avatar answered Aug 02 '26 00:08

Abdul Moiz



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!