Jump to content

Chinese characters are not rendered in Invoice PDF


Recommended Posts

Good day,

 

Just want to ask how can the PDF invoice in prestashop be set to render Chinese characters.. I've been on this since last week and I still don't have a decent solution.. Can anyone point me to a good direction to follow.. 

 

If there is a Chinese character included in the PDF it shows just plain boxes:

IX AGE [][][][][] - []

 

Something like that.. As far as I can see in the codes the Pdf generator is extending tcpdf so I am assuming that tcpdf is the one used to generate PDFs.. Is it a problem with the encoding or the font? If so, how can I change the encoding and the fonts..

 

Thanks..

Link to comment
Share on other sites

Chinese fonts have to be installed and used by your shop's code. Additionaly, these fonts have to be enclosed to every generated PDF to avoid problems on customer's computers.

 

I think, there is some core patch or recipe how to do it in PrestaShop 1.6. Anyway, using the M4 PDF Extensions module you can do it without hassle. All fonts are available to download and some templates are already adapted to display Chinese fonts (it is just about one style definition). See http://www.presta-addons.com/pdf/Invoice - Chinese address.pdf.

Link to comment
Share on other sites

×
×
  • Create New...