I see empty boxes ([][][]) instead of symbols in PDF
Default font (used by PDF library) doesn’t support all UTF8 symbols.
So if you use Chinese, Arabic, Cyrillic, Hebrew — you must install new font.
Please, use this way.
1. Download zip from https://freefontsdownload.net/free-st-gigafont-typefacescode2003-font-152444.htm
2. Run ftp client and create folder “fonts” inside active theme
3. Upload file Code200365k.ttf to folder “fonts”
4. Add following PHP code to functions.php
1 2 3 4 5 6 7 8 |
add_filter("woe_formatter_pdf_use_external_font","__return_true"); add_filter("woe_formatter_pdf_apply_external_font",function($fpdf){ $fpdf->setFontPath( dirname( __FILE__ ) ."/fonts/"); $fpdf->AddFont( 'Code200365k', "", "Code200365k.ttf" ); $fpdf->AddFont( 'Code200365k', "B", "Code200365k.ttf" ); $fpdf->SetFont( 'Code200365k', '', 12 ); return $fpdf; }); |