mudisoft Posted March 22, 2009 Share Posted March 22, 2009 Hello,First of all, forgive me if everybody's sick already with this topic which seems to be discussed all the time. I did use the search engine and I did read pretty much everything on the matter (plus the posts tagged as solved)...However I seem to be incapable of completing the task correctly and I cannot make my website (1.1.0.5 ) generate PDFs with Cyrillic symbols. I followed the steps in this post and in several other ones (I don't know if I did everything right, because I don't know Russian very well).I thought I'd share what I've tried. Sorry if I made a stupid mistake, but I don't fully understand how this PDF generating works. Please tell me if I'm doing something wrong.What I did was the following:1. I went to http://fpdf.fruit-lab.de and uploaded this font which should support the necessary symbols. I used cp1251 map and didn't customize it.2. I removed the .txt extension from the *.php file and uploaded all four files to "./tools/fpdf/font/".3. I changed the function in PDF.php with the code from here and replaced the file in "classes" dir.4. Finally, I set up the encoding to cp1251 and the font to the newly created one in Preferences -> PDFI've played with different fonts and bits of code but the result is always negative.Please help if you know how this can be solved. I would appreciate any help that you could provide. Link to comment Share on other sites More sharing options...
alekmk Posted September 20, 2010 Share Posted September 20, 2010 i did the same, and there is a error, cannot find font definition file Link to comment Share on other sites More sharing options...
DevNet Posted September 20, 2010 Share Posted September 20, 2010 Hi,I'm not sure, but read this answer :You must change the text encode in [root]/classes/PDF.php directly.The encode method is call for all text like this : Tools::iconv('utf-8', self::encoding(), 'my text') Just change utf-8 to your cp1251Best regards Link to comment Share on other sites More sharing options...
alekmk Posted September 20, 2010 Share Posted September 20, 2010 Hi ,tnx devnet for you answer,you're saying i should replace utf-8 with cp1251 in class/pdf.php ?I did that, and nothing changed Link to comment Share on other sites More sharing options...
DevNet Posted September 20, 2010 Share Posted September 20, 2010 Is your hosting server have the cp1251 encode ? Link to comment Share on other sites More sharing options...
alekmk Posted September 20, 2010 Share Posted September 20, 2010 I set PrestaShop on WAMP on my laptop.I saw in fpdf/makefonts are encoding files .map.. another thing, i migrated from FPDF to TCPDF and there is the same problem, TCPDF ERROR: Could not include font definition file: f1398de3899c0d6eddefe53443e2b2da_arial Link to comment Share on other sites More sharing options...
Recommended Posts