Store owners can translate strings within a WebToffee plugin using the WPML string translation tool and generate documents in different languages. Strings include the general admin texts, document texts, option names, and other texts within the plugin. To translate a string within a plugin, follow the below steps:
- Install and activate the WPML string translation tool.
- Now, go to WPML > Theme and plugins localization and scroll down to the Strings in the plugins section.
- Mark the checkbox next to the WebToffee plugin that you wish to translate and click on the Scan selected plugins for strings button.
- Then, go to String Translation under the WPML tab, and select the domain corresponding to the plugin from the ‘In domain‘ dropdown menu.
- Click on the ‘+’ icon under the preferred language’s flag and add the translation for the selected string.
- Switch the site language to view the translated plugin changes.
Prerequisites
- Install and activate the WPML core plugin and WPML string translation add-on.
- Install and activate the WebToffee plugin that you wish to translate.
- Ensure the required languages are selected in WPML. To know more, refer to this article.
Installing and activating the WPML string translation
To get more details on how to install and activate the WPML string translation tool, refer to this article.
String translation
Below are the detailed steps on how to translate a string within a WebToffee plugin using the string translation tool:
- From the WordPress dashboard, navigate to WPML > Theme and plugins localization and scroll down to the Strings in the plugins section.
- Now, find the required plugin from the list and check the box next to that plugin name.
- Then, scroll down to the bottom of the screen and click on the Scan selected plugins for strings button. This will scan all the strings present in the respective plugin.
- Go to WPML > String Translation.
- In the String translation page, head to the In domain dropdown menu and select the plugin domain. The dropdown lists the domains of all the plugins within your site (For eg. Let’s select the domain corresponding to WebToffee’s free WooCommerce PDF Invoices, Packing Slips, Delivery Notes, and Shipping Labels plugin as shown below).
- On selecting the required domain, a list consisting of all the strings present in the respective plugin will show up. Look out for the necessary string using the search option, or simply scroll and navigate to the required string (eg: The below mentioned GIF explains how to search for the string ‘Quantity’).
- Upon finding the required string, click on the ‘+’ icon under the desired language’s flag.
- Type in the translation in the space provided and save it by pressing the Enter key or by clicking anywhere out of the translation window. Use the Tab key to switch between languages.
- Similarly, repeat the steps for other strings and languages as well.
After adding the translations, navigate to WPML > Languages and change the default language. Here we have added the translation for ‘Quantity’ in Swedish language. So set Swedish as the default language and generate the invoice document. The invoice document will now contain the Swedish translation of ‘Quantity’ in it which is ‘Kvantitet’.
- As a final step, switch the site language to view the translated plugin changes.
Store owners can translate multiple strings at once. Store owners can also send strings to translators and perform automatic translation.
Finding missing strings inside a plugin
There can be instances where certain strings in the plugin are not available for translation. To solve this issue, follow these steps:
- From the WordPress dashboard, navigate to WPML > String Translation.
- Scroll down to the bottom of the page and find the ‘Look for strings while pages are rendered’ option and enable it by marking the checkbox.
- Proceed to the WooCommerce Orders page (WooCommerce > Orders) and generate the required document for an order (For e.g. If the missing strings are from the invoice document, generate an invoice for the order). The strings that were missing from that document type will now be added.
- Return to the WPML > String translation page, now the missing strings will be added.
- Then, add the translations for the newly added strings.
- Finally, turn off the ‘Look for strings while pages are rendered’ option.
ez
March 13, 2024
HI,
Will I be able to have the product items translated also?
Please advise
Sanjai Valsan
March 20, 2024
Hello,
Thanks for reaching out!
With the WPML string translation tool, you can translate various strings within a plugin. However, the product item names will not be translated and will remain the same.
Adi AP
August 16, 2023
Hello,
I would have a small problem vis-à-vis the create of invoices for printing. The website is in two languages: RO and EN and when I try to create the invoice for printing, the names of the products appear in EN, but the order was made in RO. When I view the invoice (after it was created), it appears in RO. Any idea why and how I can fix this?
Thank you very much.
Hema
August 21, 2023
Hello Adi AP,
Thanks for reaching out. The invoice generation is based on the WooCommerce profile language. Kindly make sure that the profile language chosen for both orders are correct. For further assistance contact customer support.
Ed
August 25, 2021
Hi, with this plugin will the customer be able to download pdf invoice from My Account?
Mark
August 26, 2021
Hi Ed,
You can download the PDF or print Invoice directly from My accounts > Orders page.
Paolo
May 4, 2021
Hi,
Where I could translate the voices of the PDF “Order”, “Date”, “Image”, “Total Weight” in languages different from english?
My website has two langs: IT and DE.
This plugin is compatible with WPML, but I can’t found the correct strings to translate in the WPML settings. How could I solve this problem?
Thanks,
Best regards
Mark
May 6, 2021
Hi Paolo,
Please follow the instructions here:
1. Open WPML string translation settings and enable “Look for strings while pages are rendered”
2. Open an order from the WooCommerce order page and print the invoice for rendering the strings.
3. Again go to the WPML string translation page and look for your desired fields and translate it.
4. You are done. Now you can disable “Look for strings while pages are rendered” option in the WPML string translation page.
Refer link for better clarification.
dev
June 4, 2019
Hello,
I used the same way but this is not working for me.
I tried by switching the langugage from WP dashboard but still no success.
One thing that I am using this plugin upgrade version i.e. 3.
Is it compatible or I need to use its downgrade version?
WPML integration support only for downgrade version?
Let me know if its not compatible and how can I get its downgrade version.
Thank you.
Mark
June 4, 2019
Hi,
The latest version is compatible with WPML. Try switching language from user profile edit page and check.
dev
June 6, 2019
Hello,
I already tried this. But still its not working.
Its only updating the “Billing Address” label from PDF after switching language from user profile edit screen.
Rest of the labels are still not translated. And I alredy set their translation in WPML > String translation.
Can you please let me know the issue
Mark
June 12, 2019
Hi,
As mentioned on the support ticket, updating the plugin to the latest version has fixed the issue for you. Hope everything works fine now.
devadmin
May 3, 2019
Hello,
I have used the same way to add string translation of invoices label in WPML.
But this is not working at my end. It is displaying the default language (English) translation.
Also I have used the custom invoice template.
Can you please let me know if I missed something here.
Thank you.
Mark
May 3, 2019
Hi,
Please try printing the invoices by switching the language from the WordPress admin dashboard. If the issue persists, please reach us via support link above.
Juergen Bauer
March 12, 2021
It is still not possible to print multi language invoices. What a pity!
Mark
March 16, 2021
Hi Juergen,
You can switch the user language and print the invoices according to users language.