Advanced Order Export for WooCommerce

I see empty boxes ([][][]) instead of symbols in PDF

Seeing small empty boxes – often displayed as [][][] or □□□ – replacing letters, logos, or characters in an exported PDF is a common but fixable issue. This Advanced Order Export Troubleshooting guide explains exactly why it happens and provides several solutions for restoring proper text rendering in the Advanced Order Export for WooCommerce plugin.

This problem almost always occurs when exporting orders containing non‑Latin scripts such as Chinese, Japanese, Korean (CJK)ArabicHebrewCyrillic (Russian, Ukrainian, Bulgarian, etc.), Greek, or other special Unicode characters (e.g., Č, š, ü, ñ). The root cause is not a bug in the plugin, but a limitation of the underlying PDF generation library it uses.

Who Is Most Likely to Experience This Issue?

The problem appears when your order data contains any of the following:

  • Chinese, Japanese, or Korean characters (customer names, product titles, shipping addresses)
  • Arabic or Hebrew scripts (especially when the store serves Middle Eastern markets)
  • Cyrillic characters (for stores based in Russia, Ukraine, Bulgaria, Serbia, etc.)
  • Greek, Thai, Hindi, or other Unicode‑intensive scripts
  • Special symbols such as € (euro), £ (pound), ©, ®, ±, ≥, ≤, or emoji
  • Accented Latin letters (é, ü, ñ, ç, etc.) – while often supported by DejaVu Sans, they can sometimes fail depending on the specific character

If your orders are predominantly in English using standard ASCII characters, you are unlikely to encounter this issue.


Prerequisite: Verify That the Data Is Present in the Source

Before following the solutions below, please confirm that the “missing” characters actually exist in your original order data.

  1. In your WordPress admin, go to WooCommerce → Orders.
  2. Open the order that contains the problematic characters.
  3. Check the customer name, product title, shipping address, and order notes for the characters that appear as empty boxes in the PDF.

If the characters are not present in the order itself, the plugin cannot export them. In that case, the character‑encoding issue is likely occurring earlier in your data entry or storage process and may require a different troubleshooting path.


How to Fix Empty Boxes in PDF Exports

There are two primary ways to resolve this issue. Both are fully compatible with the free version of the plugin.

Option 1: Install a Full‑Unicode Font (The Original Free Method)

This is the method described in the original plugin documentation. It adds a custom Unicode‑aware font that covers almost all scripts used in the world, including CJK, Arabic, Cyrillic, and Hebrew.

What you need:

  • FTP/SFTP access to your WordPress site (or a file manager provided by your hosting control panel).
  • The Code2003 font file (or any other .ttf font with extensive Unicode coverage; see the section below on alternative fonts).

Step‑by‑step instructions:

1: Download a full‑Unicode font file from https://freefontsdownload.net/free-st-gigafont-typefacescode2003-font-152444.htm. Code200365k.ttf, a large bitmap font that covers tens of thousands of characters.

2: Connect to your WordPress site using an FTP client or navigate to your hosting control panel’s file manager.

3: Navigate to your active theme’s directory: /wp-content/themes/your-active-theme/.

4: Create a new folder named fonts inside your active theme directory.

5: Upload the downloaded .ttf font file into the fonts folder you just created.

6: Add the following PHP code to your theme’s functions.php file. You can add it at the end of the file, just before the closing ?> tag (if present):

Important notes:

  • Replace Code200365k.ttf with the actual name of the .ttf file you uploaded.
  • The font file name is case‑sensitive.
  • This method affects all PDF exports generated by the plugin, not just a single profile.

Since the Code200365k.ttf file is a large bitmap font, it may not produce the most polished output for certain scripts. For better results with specific languages, consider using alternative fonts (see “Which Font Should I Use?” below).

Option 2: Switch the PDF Library to mPDF (Alternative Approach)

If the custom font method does not work for you – or if you prefer a more automated solution – you can replace the underlying PDF engine. mPDF is an alternative PHP library that provides much better Unicode support without requiring manual font installation.

However, please note:

  • This method does not automatically work with the Advanced Order Export for WooCommerce plugin out of the box. Many WordPress PDF plugins (e.g., WooCommerce PDF Invoices) offer a built‑in option to switch from dompdf to mPDF. The Advanced Order Export for WooCommerce plugin does not currently have that setting.
  • Attempting to replace the library requires custom code and a good understanding of WordPress development. Unless you are a developer, the first method (installing a Unicode font) is strongly recommended for its simplicity.

If you are comfortable with coding, you can research using Composer to install mPDF and then overriding the plugin’s default woe_formatter_pdf_use_external_font filter to point your export to mPDF instead of dompdf.


Which Font Should I Use?

The original documentation uses Code200365k.ttf because it is a large bitmap font that attempts to cover every Unicode character. It is adequate but not always aesthetically optimal for modern documents.

For better results with the first method, consider using one of these fonts instead:

Font NameBest ForWhere to Find
DejaVu SansCyrillic, Greek, Latin, Hebrew (partial)Open source, widely available
Noto Sans (by Google)Almost every script: CJK, Arabic, Hebrew, Devanagari, etc.Google Noto Fonts
Arial Unicode MSComprehensive Unicode coverageCommercial; often included with Microsoft Office
FreeSerif / FreeSansLatin, Cyrillic, Greek, Armenian, GeorgianGNU FreeFont project

To use a different font:

  • Download the .ttf file for your chosen font.
  • Upload it to the fonts folder as described above.
  • Replace every occurrence of Code200365k in the PHP code with the name of your font file (without the .ttf extension).

Advanced Order Export Troubleshooting Checklist for PDF Issues

If you have tried the steps above and are still seeing empty boxes, run through this checklist:

  1. Confirm the font is properly loaded. Add a temporary line inside your theme’s functions.php, such as error_log(‘Font path: ’ . dirname( FILE ) . ’/fonts/’);. Then run an export and check your server’s error log to see if the path is correct.
  2. Check file permissions. The fonts folder should have 755 or 775permissions. The .ttf file itself should have 644 or 664 permissions.
  3. Verify the font file is not corrupt. Try uploading a different .ttf file (e.g., DejaVu Sans) and update the PHP code accordingly.
  4. Test with a minimal export. Create a new export profile that includes only one order with the problematic characters. Export it to PDF. This helps isolate whether the issue is specific to a particular profile or global.
  5. Check for PHP memory exhaustion. If you are exporting a very large number of fonts or orders, the PDF generation process may time out. Increase memory_limit to 256M or higher and increase max_execution_time to 300 seconds in your php.ini or wp-config.php.
  6. Inspect the font path for errors. The code above uses dirname( FILE ) .“/fonts/”, which points to your active theme’s folder. If your theme is a child theme, the fonts directory must be inside the child theme folder, not the parent theme.
  7. Ensure the PHP code has no syntax errors. After adding the code to functions.php, visit any page on your site. If you see a white screen or a PHP error message, revert the change immediately and check your code formatting.
  8. Clear your server cache. If your site uses a caching plugin (e.g., WP Rocket, W3 Total Cache) or a server‑side cache (e.g., Redis, Varnish), purge the cache and run the export again.

If you have completed all the steps in this Advanced Order Export Troubleshooting guide and the issue persists, continue to the next section for support.


How to Prevent This Problem in Future Exports

Once you have resolved the empty‑box issue using either the custom font method or (if applicable) an mPDF switch, here are a few best practices to keep your PDF exports clean:

  • Keep a backup of your functions.php code and the fonts folder. If you update your theme, the functions.php file may be overwritten, causing the font configuration to disappear. Store a copy of the code snippet in a secure location.
  • Use a child theme. If you add the custom font code directly to a parent theme, a theme update will wipe out your changes. Always use a child theme for any custom code.
  • Test after every plugin update. When you update the Advanced Order Export for WooCommerce plugin, run a test PDF export to ensure your font customisation remains intact.
  • Monitor your server’s error log. If new characters start appearing as empty boxes, check the error log for messages like “Font not found” or “cannot open .ttf file”.

 

Have questions? Please submit a support request. We're always happy to help!

Advanced Order Export
for WooCommerce
PRO

From $30
Buy
✓ 30-day money-back guarantee