Press enter to see results or esc to cancel.

How To Merge Your .Po File With New .Pot File From Vendor

I’ve seen a number of people complain on ThemeForest and StackOverflow about losing their translations when vendors (read theme or plugin developers) release new versions of language .pot files for their products.

If you have translated a product .pot file into a .po file for your locale, and the product vendor releases a new version of the .pot file (with new strings and strings marked as obsolete), a simple copy-paste will result in all your translations for your locale being lost. This is quite frustrating if .pot upgrades are frequent as you have to do all that work again, every time.

There is actually a way to not lose your translations and still have an up-to-date .po file for your favorite product in your locale. You merge your .po file with the new release of .pot file resulting in an updated .po file with your changes preserved.

You can do this merging with your favorite po editing tool poedit.

How do you go about merging your po and pot file?

It’s actually quite easy.

  1. Open your localized (translated) .po file in poedit.
  2. Under “Catalog” top menu, select “Update from POT file…” menu item.
  3. Select the newly downloaded .pot file and click Open in file dialog box.
  4. Your files will merge and you will be shown a dialog with new and obsolete strings.
  5. Proceed to translate the newly translatable strings.
  6. Save and exit, your updated .po file is ready.

That’s it, your .po file is updated and your translations haven’t been lost.

Comments

Leave a Comment