public function DompdfGenerator::addPage in PDF generator API 2.x
Same name and namespace in other branches
- 8 src/Plugin/PdfGenerator/DompdfGenerator.php \Drupal\pdf_api\Plugin\PdfGenerator\DompdfGenerator::addPage()
Add a page to the generated PDF.
Parameters
string $html: The HTML of the page to be added.
Overrides PdfGeneratorInterface::addPage
1 call to DompdfGenerator::addPage()
- DompdfGenerator::setter in src/
Plugin/ PdfGenerator/ DompdfGenerator.php - Set the various options for PDF.
File
- src/
Plugin/ PdfGenerator/ DompdfGenerator.php, line 87 - Contains \Drupal\pdf_api\Plugin\DompdfGenerator.
Class
- DompdfGenerator
- A PDF generator plugin for the dompdf library.
Namespace
Drupal\pdf_api\Plugin\PdfGeneratorCode
public function addPage($html) {
$this->generator
->load_html($html);
$this->generator
->render();
}