SetCompression()
(mPDF ≥ 1.0)
SetCompression – Specifies that mPDF should compress the data for the PDF file
Description
voidSetCompression ( boolean$flag )
Specifies that mPDF should compress the data for the PDF file. This makes a smaller PDF file and is set bydefault totrue on initialising the mPDF class.
Parameters
- $flag
true orfalse to specify whether mPDF should compress the data for the PDF file.
Default:true
Examples
Example #1
<?php$mpdf=new\Mpdf\Mpdf();$mpdf->SetCompression(false);$mpdf->WriteHTML('Hello World');$mpdf->Output('filename.pdf');