Custom po/mo files replaced after a certain time
-
Hello,
I want to have my own translated files for woo commercee and I used the following code in order to load my customs translation files from a safe folder located at /wp-content/languages/my_custom_folder/
The files into this folder are my custom files and are woocommerce-fr_FR.mo and woocommerce-fr_FR.po
add_action( ‘init’, ‘load_custom_plugin_translation_file’ );
function load_custom_plugin_translation_file() {
$locale = apply_filters( ‘plugin_locale’, get_locale(), ‘woocommerce’ );
load_textdomain( ‘woocommerce’, WP_LANG_DIR . ‘/my_custom_folder/woocommerce-‘ . $locale . ‘.mo’ );
}My custom files are correctly loaded and after a certain amount of time, maybe, 1day, woo commerce seems to generate a new bundle of newly created po and mo into the /wp-content/languages/plugins.
Then woocommerce use these files and not my own !!!
Could you help please???
- The topic ‘Custom po/mo files replaced after a certain time’ is closed to new replies.