Skip Navigation

This is the technical support forum for WPML - the multilingual WordPress plugin.

Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.

This topic contains 3 replies, has 1 voice.

Last updated by Kresimir 41 minutes ago.

Author Posts
February 24, 2025 at 3:01 pm #16741754

Kresimir

Background of the issue:
I am using WPML to translate WooCommerce admin texts like the store address. After using String translation, the plugin started generating .mo and .php files for content not translated using String translation. The files include 'wordpress-LANG.mo' and 'wordpress-LANG.l10n.php', which store product attribute translations. I want these translations stored only in the database.

Symptoms:
The plugin generates .mo files for product attributes, which I want stored only in the database.

Questions:
Why does WPML generate .mo files for product attributes when I only translated WooCommerce admin texts?
How can I ensure product attribute translations are stored only in the database?

February 26, 2025 at 12:23 pm #16750937

Kresimir

Hi, when can we expect an answer on this? This is a big problem which we would like to address ASAP because it's urgent for our client.

February 26, 2025 at 2:26 pm #16751579

Otto
Supporter

Languages: English (English ) Spanish (Español )

Timezone: America/Argentina/Buenos_Aires (GMT-03:00)

Thank you for contacting WPML support.
While you are waiting for one of my colleagues to take this ticket and work on it, let me provide you with the first debugging steps or if I can help with the issue quickly.

WPML generates .mo files to leverage how WordPress core loads translations. WPML creates these files from the translations stored in the database so your site can benefit from WordPress’s built-in performance optimizations when loading strings.

At the moment, WPML does not include an option or setting to completely disable generating .mo files.

Can you please elaborate on why this is an issue for your client? If it's a common scenario we may consider this as a feature request, but in any case, it will take time 🙁

Best Regards,
Otto

February 27, 2025 at 2:25 pm #16756664

Kresimir

I wouldn't agree that WPML generates those files for all of the translations as those files didn't appear until we translated a few strings using String translation.

We use WPML on a lot of other projects and don't have those files on any of them. This is the first time seeing those files. Since those files appeared, it's been impossible to change translations of WooCommerce product attributes. Which I don't think needs explanation why it's an issue. Furthermore, we seem to be having caching problems with custom post types, whose slugs translations are for some reason also stored in those files.

Why are there so many language .json files for one language? (I'm attaching a screenshot).

Screenshot_1.jpg