Home » Documentation » Related Projects » WooCommerce Multilingual

WooCommerce Multilingual

WooCommerce lets you build e-commerce sites with WordPress. WooCommerce Multilingual makes it fully compatible with WPML.

What you’ll need:

  • The recent version of WooCommerce. WPML support is available from version 1.4 and above.
  • The recent version of WooCommerce Multilingual (will also be available from the WordPress plugins repository soon)
  • The recent version of WPML, including the String Translation and Translation Management modules. WooCommerce support is available from version 2.4.2 and above

Now that you have all plugins installed and activated, you can start adding translations.

Translating Store Pages

WooCommerce can automatically create the store pages for you, but you’ll need to translate them.

Go to Pages:

WooCorremce pages to translate

If you see a + icon next to these pages, click on it. This will add the translation.

You should copy the shortcodes from the original language. For example, this is what we see in the Cart page:

WooCommerce cart page content

This shortcode tells WordPress to display the cart. You need to have it in all translations. The translated pages have a button that lets you copy from the original language. Use it to copy the page content.

Make sure that you are translating the correct page. Please look at the right sidebar top, where is, ‘This is a translation of’ text. E.g, If you are translating the cart page, there should be selected default language cart page.

Hint: if you’re using WPML’s Translation Management module, you can select all the e-commerce pages together and send them all to translation. In the translation editor, copy the content from the original language.

When you’re done, go to WooCommerce settings page and then select the pages tab. There you should have the same settings for the main language as in a screenshot.

WooCommerce pages settings

Translating Products

Similarly to the e-commerce pages that you’ve translated, you should also translate the products themselves.

The Products list is a custom admin page and doesn’t include WPML’s translation controls (the + and pencil icons).

You can translate products either when editing them or using WPML’s Translation Management module.

This is how the product-edit page looks like:

Product edit

You can translate by clicking on the + icon.

WPML will automatically synchronize the non-text attributes of products. This includes the cost, weight dimensions and other features that don’t require translation. You can translate the names and description. If you want, you can enter the same names in different languages.

Translating Product Categories

At the bottom of the page you can set the language of category and switch languages at the top of the page.

Translating product categories

Translating Attributes

Go to Products -> Attributes -> Configure terms. At the bottom of the page you’ll see the available languages.

Translating attributes

Translating General Texts

Your e-commerce site includes many small texts that are not part of any page or product. These come from the theme and from WooCommerce.

Both the theme and WooCommerce should come with their .mo files. You can complete any missing translations using WPML’s String Translation module. Follow the instructions for theme localization.

Then, go to WPML->String Translation to actually translate the texts.

All WooCommerce strings are under context ‘plugin woocommerce’. You can use the Search tool to quickly find the texts that you need to translate.

For example, this is the ‘order tracking’ page:

Order Tracking page

It includes several strings that need translation (highlighted).

Go to WPML->String Translation, set the context to ‘plugin woocommerce‘ and search for each of these strings:

Translating strings

Click on the ‘translations’ link to open and edit them. Translate, click on the ‘translation is complete‘ box and save.

Inventory, Emails and Other E-Commerce Backend Issues

You might have noticed that WPML creates new products per language. Regardless of which language visitors used to order products, the shop admin will always see the items in the default language being ordered. This allows to manage inventory and track shipments correctly.

Visitors will receive all notification emails in their right language. For this to happen, the site admin must provide the translations. Like other texts, emails are translated via the String Translation screen.

We’ve made every effort to design a completely native feel for customers and shop admins. If you need any help, please use our technical forum.

34 Responses to “WooCommerce Multilingual”

  1. David says:

    Hi there!
    Does the plugin support switching of .mo files – if existing?

    For example, I will my store in German and Dutch language – and WooCommerce already has these 2 translations on board. So there’s no need to translate the nearly 1,700 strings with your “String Translation” extension, right?!? — The “String Translation” interface is not that useful for this massive amount of strings!

    Switching the existing .mo files on language change is far better, and webmasters could also use the “Mo Cache” plugin which really speeds up the site!

    Thanx, Dave from Germany :)

    • Amir says:

      You can translate these strings with a .mo file or with WPML’s String Translation. With both techniques, you can translate just the strings that you like. There’s no need to translate all the admin strings. You can search for the specific strings that you want to translate, and translate just those.

      WPML sets the locale and WooCommerce loads its correct .mo file.

      BTW, WPML also caches string translation results, so it works pretty fast for the front-end.

  2. Silvia says:

    Hi,
    I’m using WooCommerce 1.5, WPML Multilingual CMS 2.4.3, WPML String Translation 1.3.0, WooCommerce Multilingual 1.0
    but in WPML->String Translation I can’t get the context “plugin woocommerce” with all the WooCommerce strings.

    In WPML-> Theme and plugins localization when I try to select Translate by WPML it doesn’t let me save. Every time I refresh the page it’s always selected Translate using .mo files…

    What should I do?

  3. Valieriy says:

    Hi Guys,

    I’m using woocommerce + wpml. I’m setting up product with many price variations and can’t find a way to sync those price variations across all the languages. Is it actually possible?

    • Dominykas says:

      Hi Valieriy, it’s possible if you’re using the latest version of WooCommerce Multilingual. Currently a newer version isn’t uploaded in the WordPress plugins repository, because still we’re doing some tests, I sent to you an updated version of WooCommerce Multilingual (beta), so you can use it before than, we’ll release it.

  4. Benoit says:

    Hello, How do you translate product attributes? and it seems that I can’t get product variation to work properly. I have a site in french/englsh and french is my default language. When I select french as the admin language, when I click on add variation button, nothing is happening. If I switch back to english (as my admin language), it works !?!? Any help would be quite appreciated.

    • Benoit says:

      ok product variation’s working fine. They only thing left are product categories and attributes…any instructions on how to translate those?

      Thanks

      • Amir says:

        Can you post about it in our forum? When you do that, include the tag ‘ecommerce’ and it will get to the right developer.

  5. Matthias says:

    For any reason, Woocommerce can not load the .mo files when I switch languages.
    Only if I define the language in my wp-config it will show the proper woocommerce translations. But it’s not switching with the language switcher… Is there any solution for this problem? My theme-.mo’s are loaded correctly.

    • Amir says:

      We haven’t tested it, but we will (hopefully tomorrow). What you’re describing might be possible, if WooCommerce loads the .mo files before the WordPress init has completed and WPML has had a chance to set the locale. Dominykas will reply here with an update after he tested it.

    • dominykas says:

      ‘Translate using .mo files’ doesn’t work properly, You should use:

      1) ‘Translate by WPML’ option
      2) Scan ‘WooCommerce’ plug-in for strings
      3) Make sure that ‘Load translations if found in the .mo files.’ is marked as checked

      If there will be any problems let me know.

      Thanks!

      • Matthias says:

        Ok, I’ll do that. I think the problem is, that woocommerce loads its textdomain in the constructor of their Plugin-Class. I’m quite sure that this is too early… Did you already ask them to change that? Actually it’s just too lines of code, isn’t it? I will try to hack the class by myself, but it’s stupid, if it will be overwritten with the next update.

      • Matthias says:

        I just copied line 85 / 86 of woocommerce.php to line 305 / 306, so that the load_plugin_textdomain()-member-function is called at the init-hook.
        Now it works. Didn’t check it for side-effects so far, but we will see.

        • Thirty says:

          Hi Matthias,

          I’m experimenting the same issue and so i’m really interested by your “hack”.

          You’ve copied this line (86) :
          $this->load_plugin_textdomain();

          Just before this one (307) :
          function load_plugin_textdomain() {

          Is-it right?

          Thanks in advance for your reply.

          ThirtyThirds

  6. Zjan Preijde says:

    Hi guys,
    I have a minor issue with your language selector filter.
    I did not understand why it sometimes went to a page with ?post_type=product in the URI. But your filter will redirect anything with ‘product_type’ or ‘shop’ in the URI. That means also any URI with ‘bishop’, ‘shop-in-shop’, ‘other-shops’, ‘grasshopper’, etc. (for a more complete list check Words containing shop).
    Adding remove_filter('icl_ls_languages', 'wpml_ls_filter'); in my functions.php made this go away, but I do not really understand why it is there in the first place.
    Grtz, Zjan

    • dominykas says:

      There was an issue with translations of main shop page, because translations hasn’t reproduced the main shop page, so we intended to add redirect to ‘post_type=product’. By the way, it doesn’t affect SEO, because this redirect is in question when you’re going to yoursite/shop/ page. There’s another filter which do that. If you commented icl_ls_languages filter then languages selector will not work properly in the main shop page (it will not change the language of this page). Why do you need this change?

  7. Ilze says:

    As I understand right now it is not possible to switch languages with mo files ?

  8. dominykas says:

    Hi Piet,

    Yes – it should works fine for me. I replied in your forum thread about that, also I sent an e-mail to you if it still doesn’t work for you properly.

  9. Peter says:

    I’m having a terrible job trying to locate the MO file for Spanish for CartPress. I would be awfully grateful if somebody here could point me in the right diection, please :) PdeP.

    • Amir says:

      Normally, the CartPress folks would know where they keep that .mo file. Have you asked them?

    • Peter says:

      Hi Amir: The polite reply is to say that I’d be very pleased if they were half as quick as you are in monitoring posts to their site. The not so polite answer we’ll put aside in the interests of being sociable with everybody.

      Yes, you’d think this was a pretty basic request, wouldn’t you? There are links on the site but they go around a few pages and you eventually end up back where you started – but with no download link to the file.

      My post earlier here was a cross-fingured hope that somebody might know and could give me a lead. Thanks for your help in replying – it’s most kind of you when it’s really not your ‘pigeon’.

  10. David says:

    Hello Amir,

    I’m currently using:
    WooCommerce 1.5.5, WooCommerce Multilingual 1.2, WPML CMS 2.4.3, WPML string translation 1.3.0, WPML Translation Management 1.2.9, and the Wootique free theme (for testing)

    Whenever I activate both WooCommerce and WPML CMS, I got a fatal error. Both plugins work ok separately.

    Any guidelines?
    regards
    -David

Leave a Reply

Please leave here comments about this page only.
For technical support and feature suggestions, head to our forum. We are waiting there!

You can use these tags:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>