The Product Add-On extension for WooCommerce allows you to customize products with options such as input boxes, checkboxes, and dropdown menus. With WooCommerce Multilingual, you can translate any product add-on you create.
To customize and translate product add-ons, you need the following plugins installed and active on your site:
- WooCommerce Product Add-Ons
- WooCommerce Multilingual
- WPML CMS Multilingual
- WPML String Translation
- WPML Translation Management
- WPML Media Translation
We recommend using WPML’s Advanced Translation Editor if you are translating the site yourself or using local translators. It includes many great tools such as automatic translation, translation memory, a spell checker, and more. To enable it, go to WPML → Settings. Under the How to translate posts and pages section, choose Use WPML’s Advanced Translation Editor.
There are two types of add-ons you can create for your products. They each have different translation workflows:
- Per-product add-ons are used for specific products.
- Global add-ons are used for multiple products in your store based on the product categories you select.
You can also translate other strings related to Product Add-ons such as front-end fields and labels.
To create per-product add-ons, create or edit a product, and go to the Add-ons tab in the Product Data section.
There, you can add any number of groups that hold your custom products’ add-ons. You can also choose how users select the options on the front-end: as checkboxes, dropdown menus, etc.
When you finish creating add-ons for a product, go to WooCommerce → WooCommerce Multilingual. There, you will see a list of all the products in your site. Click the Plus icon for the corresponding language and the product you wish to translate. Use the Pencil or Refresh icons to update the translations of existing products.
After clicking the corresponding icon, WPML’s Advanced Translation Editor opens. Here, you can translate all fields for your product, such as title and description.
To translate the product add-ons, search for the values you created in the search bar and add your translations.
Make sure to confirm each translation by clicking the green check mark. Then, click Complete to apply the translations.
If your site uses multiple currencies, you can set custom prices for your add-on options in each currency. To do this, go to Products → All Products and edit the product that you want to customize. In the General section, choose Set prices in other currencies manually.
In the Add-ons section, click the Pencil icon to add your custom prices in each currency.
You can create global add-ons on the Products → Add-ons page. Similar to the per-product add-ons, you can add different groups of custom fields. Then, select which product categories you want to display the add-on options.
To translate global product add-ons, go to WPML → String Translation. In the In domain section, use the drop-down menu to select the wc_product_addons_strings domain.
This lists all the strings associated with your global product add-ons. Click the Plus icon for each string and add your translations.
You can set custom prices for your global add-ons in each currency by going to Products → Add-ons. Edit the add-on you want to change, and choose Set prices in other currencies manually in the Multi-currency settings section.
Click the Pencil icon to change the prices in each currency.
The Product Add-On extension features some additional fields and labels used on the front-end. For example, before selecting an add-on from a dropdown, it reads, Select an Option.
You can translate these strings on the WPML → String Translation page. In the In domain section, use the drop-down menu to select the woocommerce-product-addons domain.
Use the corresponding Plus icons to translate any listed strings.
Once you finish translating all your product add-ons, you can see the results on the front-end.