dinamiko supports this item


This author's response time can be up to 2 business days.

51 comments found.

Hi there, I have a few pre-purchase questions I hope you can answer:

1. Is there a way to change the paper size of the outputted PDF?

I’m needing to control paper size for a specific purpose and don’t want the default size of letter or whatever it’s set to.

If no setting option, I’m okay work adjusting paper size in the actual code of the plugin or mPDF code.

2. Can the typography or font be changed? For header, footer or body?

I would actually prefer to have a different font for the header vs. post content.

3. How can I include the author name with the post title and content?

My website will have multiple authors and I would like to include their names so I can give them the due credit they deserve. Again, I’m willing to modify code or create a template to get the author name in the PDF.

Just want to know these options are available whether it’s a setting or requires plugin modifications.

Thank you!

Hi johnshiloh,

1. Yes, right now only has A4 defined but it’s possible changing one line of code, see $format here for all available sizes: https://mpdf.github.io/reference/mpdf-functions/mpdf.html

2. Yes, but this has to be done manually, more info here: https://mpdf.github.io/fonts-languages/fonts-in-mpdf-6-x.html once you have your fonts loaded in mPDF library, you can set fonts (h1, p…) using CSS.

3. Yes, this can be done tweaking plugin templates.

I recommend you trying all of the above in DK PDF (free): https://wordpress.org/plugins/dk-pdf/ DK PDF Generator uses all DK PDF functionallity plus the ability to select multiple posts, add a cover and a table of contents.


Hi dinamiko,

Thanks for the quick response. I’m happy to hear the answer is yes to all of my questions. I appreciate the suggestion of trying it first on the free DK PDF plugin before upgrading to the add-on. I’ll review the referenced links to learn more.

Hi – this looks great but I tested DK PDF (free) and the PDF generated could not display Japanese characters. Is there any way to make non-latin characters work? If yes, will buy today!

Hello: How I can styling the Table of Contents in DK PDF Generator add on? I need to setup the table of contents title in bold font weight and the title list in normal font weight. Thank you.

Hi Lamar_Comunicaciones,

You can style TOC page adding CSS styles in DK PDF Settings / PDF CSS. Here you have a list of all css TOC styles and HTML markup: https://mpdf.github.io/what-else-can-i-do/table-of-contents.html

For example, this will change page list items font to normal weight: span.mpdf_toc_t_level_0 {font-weight: normal;}

Try it and tell me if it works for you.

Thanks, Emili

Hey there, I am considering buying this plugin. Question – are my jcharts visualization of Google Analytics stats going to be captured. I tried the PDF plugin and that is not happening? Thank you

Hi leafwiredigital2016,

I think that if the charts API can return an image (jpg, png…) of the chart, that image can be added to the PDF. Never user jcharts but I used Google Maps API and I went able to print maps in the PDF using the image version of the map provided by Google Maps API.


Hi! Great plugin but I was wondering if it was possible to restrict the download pdf function to selected pages or posts only. Thanks!

Hi mljo,

sorry but I don’t understand it, can you explain it a bit more? also you can write to me at emili.castells@dinamiko.com if you prefer.

Thanks, Emili

Hello there,

Thanks for your plugin i just bought it and it’s great ! Unfortunately, i cannot make it work with a category of a custom post type. Is there any way i can do it ? By the way, it’s working well with built-in WP post but that’s not what i need. Maybe i can change the code a little bit so it’ll work ? Can you help on this please ? Thank you!

Hi oiso58,

Selecting custom post type terms is not implemented in the admin yet. But you can write to me at emili.castells@dinamiko.com and we can try to find a solution, for example doing a template customization and passing term ids or term slugs to the template.

Thanks, Emili.

Hi again,

I just forgot to mention that if there are not a lot of them, you can select your custom post type posts (one by one by its title) in the first selector. The first selector will search in all your post, pages and custom post types.

Otherwise if you have a lot of them and organized by terms, will be more quickly add term slugs or term ids manually in the template.

Hi, very nice plugin.

I was wondering if it is possible to add all posts from a custom post type to a single pdf. I have about 150 posts, adding all by searching the title seems a bit complicated and time consuming.

Is it possible to create a pdf from the frontend that uses all data/posts from one custom post type?

Thanks in advance.

Hi solifugae,

it’s not possible to select all posts of a custom post type automatically yet (I’ve planed to add this feature to a future version), in the meantime you can do a template customization:

1- copy ‘dkpdfg-index.php’ template from here: https://gist.github.com/Dinamiko/c92127daedaf017c1ed03b997d79bbc6
to the root of your theme (or child theme) inside a folder named ‘dkpdfg’
more info on template customization here: http://wp.dinamiko.com/demos/dkpdf-generator/doc/how-to-use-dk-pdf-generator-templates-in-your-theme/

2 – in dkpdfg-index.php in line 42: $post_type_slug = ‘doc’; change the value of $post_type_slug to your custom post type slug, in the example I’m using a custom post type slug ‘doc’.

3 – that’s all, now you can go to admin and click ‘Create PDF’ and a PDF with all your custom post type posts will be generated.

if you can’t do a template customization (you don’t have the technical knowledge to do it) write to me at emili.castells@dinamiko.com and I can try to do it for you.


Hi Emili,

thanks for your fast reply and the easy solution to my request. It works exactly as I need it.

I have 2 more questions:

1. Can I edit the config of mPDF and will the changes affect the PDF and will an update overwrite the changes in the config.php?

2. Is there an easy way to get the exact hierarchy/order of my parent and child elements into the table of contens that is generated.

Thanks a lot!

Hi solifugae,

1. DK PDF Generator uses mPDF library from DK PDF (free) so you have to edit config.php in DK PDF (free). Edits in config.php will affect both plugins. Yes, a plugin upgrade will override your edits, so do a copy of your config.php before upgrade the plugin and once upgraded replace it with yours.

2. By default TOC uses h1 only (one level), but you can add more levels, this is how it works:
- in dk-pdf-generator / includes / dkpdfg-functions.php in lines 106 and 107:
$mpdf->h2toc = array( ‘H1’=>0 );
$mpdf->h2bookmarks = array( ‘H1’=>0 );

Adding a second level for H2:
$mpdf->h2toc = array( ‘H1’=>0, ‘H2’=>1 );
$mpdf->h2bookmarks = array( ‘H1’=>0, ‘H2’=>1 );

then if your HTML content has H2 titles, these will be added as a second TOC level. Also you can add more levels (‘H3’=>2) or make H3 second level (‘H3’=>1).

Try it and if you’re in trouble you can write to me at emili.castells@dinamiko.com


Hello I wanted to know if it was possible PDF Creation and Articles Also, private or LIMITATIONS OF a certain Users?


I’m sorry but I don’t understand the problem, can you explain it a bit more? thanks.

I’m an admin, when I go to create the PDF, and looking for an article which is private and accessible only to certain roles, I do not find.

OK understood :)

in dk-pdf-generator / includes / dkpdfg-functions.php in line 149 change this: ‘post_status’ => ‘publish’,
for this:
‘post_status’ => ‘any’,






Hi there, does this plugin work with wordpress multisite?

Also, since its GPL, can i buy the regular license and use it on my multisite for all my subsites?

Thank you very much :)

Hello, I would like to know if it can put a logo on every page that the generator creates?