About RockPdf - mPDF helper module
mPDF helper module to easily create PDF files and make debugging easier.
Modules that have more to do with assisting development of a site rather than managing its content.
Should be safe for use in production environments. *
|Date Added||August 11, 2018|
|Last Updated||September 27, 2018|
RockPdf is a wrapper for the mpdf library. Mpdf, as you may already know, is a commonly used PHP library that turns HTML content into PDF, complete with (at least basic) CSS styling, embedded images, and so on. While you could include the mpdf library directly in your code, accessing it through a module has some benefits:
First of all you have access to an instance of mpdf anywhere in your template or module files simply by calling $modules->get('RockPdf') – no need to include any additional files or anything like that.
RockPdf makes debugging layout issues notably easier by embedding parameters passed to its functions as HTML comments into the generated markup, and also by giving you an easy method to fetch the generated markup as-is.
While mpdf by default includes a massive blob of fonts, with RockPdf you get only the ones you really need – and you can still add more if needed, just by dropping the font files into specific directory.
Perhaps the most notable benefit from using RockPdf instead of directly including mpdf is related to the first bullet point above: by using RockPdf you get to keep your template and module files clean, and the API usage is always consistent. As an added bonus you also don't have to worry about keeping the mpdf library manually up to date.
This module's files should be placed in /site/modules/RockPdf/
How to install or uninstall modules
No comments yet. Be the first to post!
Your e-mail is kept confidential and not included with your comment. Website is optional.
- Admin Helpers
- Core Modules
- Development Tools
- Field Types
- Input Fields
- Language Modules
- Language Packs
- Markup Generation
- Premium Modules
- Process Modules
- Proof of Concept
- Site Profiles
- Social, Feeds, Services
- Text Formatters
- Other Modules
- Users and Access
*Use modules at your own risk. There are no guarantees or warranties. It is recommended that you backup your site and database before installing new modules.