Upgrading mPDF Library

Hi All,

Appreciate your help…

We are working with complex script text. And we want to export it to pdf. But the pdf library (mPDF 5.7) does not support the complex script . We need to update mPDF library.
Could someone direct us how to do that.

Best Regards


What’s your SuiteCRM version and your PHP version?

Have you checked the relevant issues on GitHub?

Version : 7.11.6
I haven’t checked in GitHub

You have this one

which seems to be merged into develop branch, but I don’t think it’s part of any release package yet.

1 Like

I can’t find mPDF and its version in composer.json

It’s been deprecated. Use TCPPDF now.

Which SuiteCRM version do you have? (it helps if you always state it)

Hey pgr,
Thanks for the info regarding the deprecation of mPDF.

Is there a known reason why it was deprecated? Is it really just that mPDF isn’t supported by PHP 8.0+ as this thread seems to indicate?

I recently upgraded my system and the deprecation significantly changed my PDF rendering appearance (for the worse). I was using custom HTML with mPDF module and had my PDFs rendering beautifully. Since the force over to TCPPDF, this rendering module doesn’t seem to support padding or width attributes in table cells, which makes it very difficult to stylize PDF output now.

I would like to look at adding the mPDF module back in, but I can’t seem to find anyone who has done this yet, and as the user CRMSigns pointed out on the other thread, it’s not listed in my apt list. Are you familiar with any other cases/walkthroughs of folks adding other PDF modules that I could follow?

1 Like

I’ll answer in that other thread you linked.

1 Like

Looking at mPDF’s repo, it seems like it’s not only supported by PHP8.0, it goes up to PHP 8.3

Github - mpdf/mpdf: Requirements - PHP versions and extensions


I would say that the problem is that the mPDF inside SuiteCRM is not the latest, in fact, it’s probably far from the latest. So I’m pretty sure the mPDF we had did not support PHP 8.0.

And upgrading it involves some dev work which was deemed not worth the effort. But I heard that the ultimate reason for abandoning had to do with unclear/inadequate licensing.

I agree 100%. Our sales people had many templates looking perfect and when I updated SuiteCRM it created a huge mess for them. I have been trying to recreate the templates in TCPPDF but no matter what I do they look much worse. mPDF produces much better PDFs in my opinion.

1 Like

@mcom I feel your pain! When I updated I had a bunch of PDF templates to re-configure too. Took many hours. Has to be done, once you get them done it’s done!