Web view template renders pdf


This is a work in progress that i hacked together but I wanted to render the invoice pdf in the browser instead of using the web template.

Template uses PDF.js to display the pdf in the browser.

It’s responsive and resizes accordingly and works in all the browsers I’ve tried so far. My html is limited so if anyone has any ways to improve upon this I’d appreciate the help.

default-pdf.php (3.2 KB)
Upload to application/views/invoice_templates/public

Get PDF.js from http://mozilla.github.io/pdf.js/getting_started/

To make it easy you can download the pre-built then extract web and build folders to root of InvoicePlane.


Thanks so much for this post. I uploaded all the files you provided, where do I go next to test it or see it in action?