How does WordPress choose which translation file to use?

One of my WordPress plugins has ended up with 2 different sets of translations for the same exact language (Spanish)… there’s the one set of .mo/.po files I bundle with the plugin itself, and another set that the WordPress.org community translators created. If your site language is set to Spanish it downloads both… so my question is, which one is it actually using? (mine or the community one?)

I know with WP theme templates there’s a hierarchy of inheritance that tells you exactly the order in which it looks for template files… basically I’m looking for some documentation like this but for language files, i.e. in what order does WordPress look for language files? (I’ve searched in vain… hoping someone out there knows!)

Update 2017-07-16: the 2 sets of translations are located in the following directories:

Community translation: /wp-content/languages/plugins

My translation: /wp-content/plugins/[my-plugin-name]/languages

0

Leave a Comment