class PDFGenerator

Class PDFGenerator

Methods

Mpdf
getMpdf(array $constructorArgs = array())

Get an instance of mPDF class

mixed
generatePdf(mixed $html, array $argOptions = array())

Generate pdf from html

Response
generatePdfResponse(mixed $html, array $argOptions = array())

Create new response and set content type to pdf

setAddDefaultConstructorArgs(mixed $val)

No description

string
saveToFile(string $fileName, string $mode, string $htmlTemplate, array $argOptions = array())

Save pdf to file

bool
getAddDefaultConstructorArgs()

No description

Details

at line 33
Mpdf getMpdf(array $constructorArgs = array())

Get an instance of mPDF class

Parameters

array $constructorArgs arguments for mPDF constror

Return Value

Mpdf

Exceptions

MpdfException

at line 57
mixed generatePdf(mixed $html, array $argOptions = array())

Generate pdf from html

Parameters

mixed $html
array $argOptions

Return Value

mixed

Exceptions

MpdfException

at line 74
Response generatePdfResponse(mixed $html, array $argOptions = array())

Create new response and set content type to pdf

Parameters

mixed $html
array $argOptions

Return Value

Response

Exceptions

MpdfException

at line 90
PDFGenerator setAddDefaultConstructorArgs(mixed $val)

Parameters

mixed $val

Return Value

PDFGenerator

at line 108
string saveToFile(string $fileName, string $mode, string $htmlTemplate, array $argOptions = array())

Save pdf to file

Parameters

string $fileName
string $mode
string $htmlTemplate
array $argOptions

Return Value

string

Exceptions

MpdfException

at line 120
bool getAddDefaultConstructorArgs()

Return Value

bool