'Dynamic DOMPDF custom fonts issue and page break functionality

I have a quiz built on WordPress. After a user takes the quiz the results will be mailed to the user's email address as a PDF. So the PDF is not supporting the custom fonts (II Voorkurs). We have used all options such as @fontface etc.. but still not working.

The second issue is that the content on the PDF is dynamic (text length varies as per the user test score). So this makes some elements break when there is a page break in PDF.

Cann anyone help me out?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source