• Resolved angeldev

    (@angeldev)


    Question: What is the correct folder to place the .po and .mo files in, to translate the plugin core?

    When WP-ERP plugin was updated recently, to v1.11.1 -> August 26, 2022, I noticed soon after that translations I had put in place were no longer working.

    I had previously put the .mo file in: /wp-content/plugins/erp/i18n/language folder, as per the documentation (https://wperp.com/docs/erp-core/how-to-translate-wp-erp-plugin/translating-the-wp-erp-core-plugin/) and it was working fine, my translations were showing correctly.

    After the update of the plugin, I noticed that the .mo file had been wiped away, and new versions of erp.pot and erp.php had been put in that folder. I downloaded the new .pot file and merged it using PoEdit, there were just a few new strings had been added, I saved a new .po and .mo files and uploaded to /wp-content/plugins/erp/i18n/language folder. My translations were back, working OK now.

    Is deletion of the .mo file going to happen again, whenever the plugin is updated, or a change is made to the .pot file? Is there a different folder where I should place the .mo file, so it avoids being deleted when the plugin gets a new version?

    WP Version 6.0.2
    WP ERP Version 1.11.1 by weDevs | Auto-updates enabled
    Server architecture Linux 3.10.0-962.3.2.lve1.5.63.el7.x86_64 x86_64
    Web server LiteSpeed

    The page I need help with: [log in to see the link]

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Md. Tanvir Chowdhury

    (@tanvir101)

    Hello @angeldev

    Firstly, the .mo file was not deleted, rather it was never included. We provide the .pot file including the translatable strings that can be translated in the way customers want.

    Secondly, it’s obvious any custom codes/files inside the plugin will be removed on every update. In that case, the .po .mo files need to be inserted into the system translation directory of WordPress.

    So you can insert your custom translations inside
    /wp-content/languages/plugins/ directory.
    Those files should not be affected by plugin updates.

    The file format should be {text_domain}-{locale}.mo . The {text_domain} is erp for WP ERP, and The {locale} is the global locale format for example bn_BD for Bengali (Bangladesh).

    Thanks

    Plugin Support Md. Tanvir Chowdhury

    (@tanvir101)

    Hello @angeldev

    I assume you have found the solution to your query after following the process I have provided.
    Due to the inactivity, I am closing this topic as resolved.
    You are welcome to create another one if needed.

    Regards,

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Translation files .mo / .po deleted in v1.11.1’ is closed to new replies.