This is the class expHTML2PDF5 a wrapper for using html2pdf v5.0.x
package |
Subsystems |
---|---|
subpackage |
Subsystems |
__construct(string $paper_size = HTMLTOPDF_PAPER, string $orientation = "portrait", string $html = null, boolean $use_file = false)
string
page size
string
page orientation
string
html code for page
boolean
a flag to show $html is an html file location to be loaded
createpdf(string $mode, string $file) : string|boolean
string
How to output (constants from this same class).
string
The PDF's filename (the usage depends on $mode.
string|boolean
Depending on $mode, this may be success (boolean) or PDF (string).
installed()
output(integer $compress = null) : string
integer
compress the output
string
render()
set_grayscale( $mode)
set_html(string $html)
string
New html content. It replaces any previous content.
set_html_file(string $htmlfile)
string
the html file to use
set_orientation(string $orientation)
By default orientation is portrait.
string
orientation of paper
set_page_size(string $size)
string
Formal paper size (eg; A4, letter...)
set_paper(string $size, string $orientation = 'portrait')
string
Formal paper size (eg; A4, letter...)
string
orientation of paper
stream(string $filename, array $options = null)
string
the pdf file to output
array
options 'compress' = > 1 or 0 - apply content stream compression, this is on (1) by default ◦ 'Attachment' => 1 or 0 - if 1, force the browser to open a download dialog, on (1) by default
pdf :
size :
orient :
PDF_DOWNLOAD :
PDF_ASSTRING :
PDF_EMBEDDED :
PDF_SAVEFILE :
PDF_PORTRAIT :
PDF_LANDSCAPE :