From 8329381728ec236cc9ffb9293e235ceba90fff0e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Pohorsk=C3=BD?= Date: Fri, 23 Nov 2018 13:40:18 +0100 Subject: [PATCH] Allows to print pdf inline with pre-filled filename --- src/Document.php | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/Document.php b/src/Document.php index d276aa6..d9309bc 100755 --- a/src/Document.php +++ b/src/Document.php @@ -104,6 +104,16 @@ public function printPdf() } + /** + * Print a PDF file to screen and sets filename + */ + public function printPdfInline($filename) + { + $this->finalize(); + return $this->mpdf->Output($filename, 'I'); + } + + /** * Returns instance of mPDF. *