wkhtmltopdf 0.12.6 - Footer Not Rendered
mihir8400 opened this issue · 3 comments
wkhtmltopdf --version
wkhtmltopdf 0.12.6
I'm encountering an issue with wkhtmltopdf version 0.12.6 where the footer is not rendering in generated PDF.
I am trying both way using "view" and the simple way "footer-center"
Code is given below.
`$mainhtml = view('web.digital_quote.generate-pdf', compact('data'))->render();
// $footerhtml = view('web.digital_quote.pdf-footer')->render();
$footerhtml = '
$pdf = PDF::loadHTML($mainhtml)
->setPaper('a4')
->setOption('footer-center', $footerhtml);
$pdfName = 'digital_quote_.pdf';
return $pdf->stream($pdfName);
`
I have exactly the same problem here.
You can try option 'footer-html'
$pdf = PDF::loadHTML($mainhtml)
->setOption('footer-html, view('web.digital_quote.pdf-footer'));
You can try option 'footer-html' $pdf = PDF::loadHTML($mainhtml) ->setOption('footer-html, view('web.digital_quote.pdf-footer'));
already done but not work,
Here I want The footer remain on the last page
Not each page