Setup #
Requirements:
- Polylang
- Polylang WooCommerce addon (recommended)
Note: While Polylang by itself allows for PDF translations, managing multilingual content efficiently is difficult without the Polylang WooCommerce addon. This documetation focuses on the basics of our Polylang compatibility.
WooCommerce > PDF Invoices > Pro
At WooCommerce > PDF Invoices > Pro, unless you need to set the language to a fixed one, set the Document language to Order/customer language.
With Polylang configured, users will receive their documents in the language in which Polylang set their Checkout at the time of purchase,
Polylang also enhances certain settings of our Invoicing plugin by adding multi-lingual tabs to them. These language tabs are set via the Polylang ‘Languages’ menu.
The following list shows how the multilingual tabs appear for compatible settings.
Multilingual settings #
All document settings are saved in the WooCommerce order meta. These multilingual settings keep existing even if Polylang is uninstalled.
Shop Name #
- Path: WooCommerce > PDF Invoices > General
Note that the Shop Name setting is selected in French:
Result on document in French:
Shop Name setting selected in German:
Result for document in German:
Shop Address #
- Path: WooCommerce > PDF Invoices > General
Footer #
- Path: WooCommerce > PDF Invoices > General
Extra template fields #
- Requirement: Premium Templates extension
- Requirement: Modern template
- Path: WooCommerce > PDF Invoices > General
Document title #
- Path: WooCommerce > PDF Invoices > Documents, select the document type then scroll to Document title.
PDF filename #
- Path: WooCommerce > PDF Invoices > Documents, select the document type then scroll to PDF filename.
Document number label #
- Path: WooCommerce > PDF Invoices > Documents, select the document type then scroll to Document number label.
Document date label #
- Path: WooCommerce > PDF Invoices > Documents, select the document type then scroll to Document date label.
Due date label #
- Path: WooCommerce > PDF Invoices > Documents, select the document type then scroll to Due date label.
Address customization #
- Requirement: Professional extension
- Path: WooCommerce > PDF Invoices > Pro
Enjoy different address structures based on your document language.
The fields to overwrite the Billing Address:
Similar to above, the fields to overwrite the Shipping Address:
Custom Block translation #
- Requirement: Premium Templates extension
The content from Custom Blocks is not translated by default, as demonstrated in the Invoice below. The document language below is in French, so we expect our text to be in French, not in English – as shown below.
This image below shows the Custom Block that is producing this text:
As seen in the image above, there are no multilingual tabs.
In order to translate these strings, they need to be searched via the Polylang settings at Languages > Translations.
Once in Polylang’s Translation settings, the arrow below indicates where to search the text to be translated.
The square shows the search results, showing the results of the search.
When viewing the search results, the Group should always be PDF Invoices & Packing Slips for WooCommerce – Premium Templates.
From here, the desired text can now be set per language.
Here is the result on a document:
Troubleshooting #
- When viewing search results from the Polylang translation settings at Languages > Translations, it is important to take note of both the Name and Group of the result.
- Remember to leave the the Document language setting at ‘Order/customer language’ to avoid sending all your customers documents in the same forced language.
WooCommerce > PDF Invoices > Pro