Definition at line 236 of file pdf.inc.
◆ __construct()
ExternalPDFConvertor::__construct |
( |
|
$pdf | ) |
|
◆ coverPage()
ExternalPDFConvertor::coverPage |
( |
|
$url | ) |
|
Provides a separate URL to use as the cover page of the PDF.
- Parameters
-
string | $url | the URL used to generate the cover page |
- Returns
- PDF
Definition at line 251 of file pdf.inc.
◆ footer()
ExternalPDFConvertor::footer |
( |
|
$text, |
|
|
|
$position = "center" , |
|
|
|
$size = 11 |
|
) |
| |
- Parameters
-
$text | - text of the footer |
$position | - valid positions are left, right, and center |
$size | - font size for the footer ?? doesn't work |
Definition at line 264 of file pdf.inc.
◆ generate()
ExternalPDFConvertor::generate |
( |
| ) |
|
Definition at line 269 of file pdf.inc.
281 $uri = $this->pdf->uri;
282 $uri = appendToQueryString(
$uri,
"__pdfoutput=1");
283 if ($this->pdf->landscape)
285 $uri = appendToQueryString(
$uri,
"__pdflayout=landscape");
288 if ($this->pdf->useToken)
291 $uri =
"/action/auto_login/authenticate?token=$token";
294 $urlparam =
"http".($this->pdf->ssl?
"s":
"").
"://".
$config[
"http_host"].
$uri;
300 if ($this->pdf->output)
302 file_put_contents($this->pdf->output,
$content);
static createOneTimeToken($url, $ip_addr=null)
FakoliException is the base exception class for all Fakoli errors.
static getValue($component, $name)
Retrieve the value of the specified Setting.
if(array_key_exists("HTTP_IF_MODIFIED_SINCE", $_SERVER)) $content
◆ preProcessTemplate()
ExternalPDFConvertor::preProcessTemplate |
( |
|
$template | ) |
|
Definition at line 347 of file pdf.inc.
349 if (!isset($_GET[
"__pdfoutput"]))
return $template;
350 $layout = ($_GET[
"__pdflayout"] ==
"landscape") ?
" @page { size: landscape; }" :
"";
351 $styles =
"<style type='text/css' media='print'>{$layout} @page {margin:0;} body { margin: 1.5cm }</style></head>";
353 $template = preg_replace(
"/<\\/head>/i",
$styles, $template);
◆ screenshot()
ExternalPDFConvertor::screenshot |
( |
| ) |
|
Definition at line 308 of file pdf.inc.
320 $uri = $this->pdf->uri;
321 $uri = appendToQueryString(
$uri,
"__pdfoutput=1");
322 if ($this->pdf->landscape)
324 $uri = appendToQueryString(
$uri,
"__pdflayout=landscape");
327 if ($this->pdf->useToken)
330 $uri =
"/action/auto_login/authenticate?token=$token";
333 $urlparam =
"http".($this->pdf->ssl?
"s":
"").
"://".
$config[
"http_host"].
$uri;
339 if ($this->pdf->output)
341 file_put_contents($this->pdf->output,
$content);
The documentation for this class was generated from the following file:
- C:/code/cms.sonjara.com/cms/components/pdf/pdf.inc