Hi,
As emails are created on server side, it’s impossible to know the language of the client. There is however another possibility – to display language depending on billing country of current order. For that you need to add billing_country and not_billing_country attributes to shortcodes, something like this (example is from http://booster.io/multilanguage-pdf-invoice-example/):
[wcj_text billing_country="FR,BE"]Facture[/wcj_text]
[wcj_text billing_country="DE"]Rechnung[/wcj_text]
[wcj_text not_billing_country="FR,BE,DE"]Invoice[/wcj_text]
[wcj_order_number billing_country="FR,BE" before="Numéro de commande: "]
[wcj_order_number billing_country="DE" before="Bestellnummer: "]
[wcj_order_number not_billing_country="FR,BE,DE" before="Order number: "]
Please let me know if that helped.
Best regards,
Tom
P.S. If you like Booster, please leave us a rating.
-
This reply was modified 9 years, 4 months ago by
Algoritmika.
-
This reply was modified 9 years, 4 months ago by
Algoritmika.
Hi,
Thanks for t=your quick answer. Will try this. However, I’ve managed to have translated emails in English. Unfortunately, there is no polish version 🙁
Hi,
Could you please post here (or send it to [email protected]) the code which you are using?
Best regards,
Tom
Hi,
Here is the code:
[wcj_wpml_translate lang="pl"]Twoje zamówienie zostało już wysłane! Niedługo będziesz mogła cieszyć się nim w domu.[/wcj_wpml_translate]
[wcj_wpml_translate lang="en"]Your order has been shipped! You will receive it soon.[/wcj_wpml_translate]
Hi,
As I mentioned earlier, you can’t use lang attribute in emails, as emails are created on server, so it’s always the same language there. However please try this:
[wcj_text billing_country="PL"]Twoje zamówienie zostało już wysłane! Niedługo będziesz mogła cieszyć się nim w domu.[/wcj_text]
[wcj_text not_billing_country="PL"]Your order has been shipped! You will receive it soon.[/wcj_text]
Best regards,
Tom
Thanks, I will try this one 🙂
Hi,
I’ve tried this code for orders from Poland, Germany and United Kingdom, however all emails were sent in English. 🙁