Fix Option Translations
This extension 'fixes' some configuration options that may have been set in English during the initial installation before you decided to switch to another language (or before improving/updating the translation files).
In short, it will update most CiviCRM option group and option value titles, as well as profiles and report instances, by attempting to translate the strings (using the CiviCRM core translation files, assuming they have been installed, see uplang for help with that process).
IMPORTANT: You cannot revert the process. If you want to switch back to English afterwards, you will have to translate your configurations manually (or you could enabled detailed logging, but that still requires a fair amount of fiddling in SQL.
Currently the extension does not handle multi-lingual sites. It might work if you enable the extension from the CiviCRM Extension Manager (web interface), while your interface is in the target language. It has not been tested yet.
The extension is licensed under AGPL-3.0.
Requirements
- PHP v7.4+
- CiviCRM 5.x
Installation
Install has a regular CiviCRM extension.
Usage
Enable the installation. After that, it can be left enabled or it can be disabled.
You can also re-run the process from the command-line, if necessary:
cv php:eval 'CRM_Fixoptiontranslations_Utils::updateOptions();'
cv php:eval 'CRM_Fixoptiontranslations_Utils::updateReportInstances();'
When successful, it does not output anything.
Known Issues
There is a slight risk that, for languages using the latin alphabet, the following scenario could happen:
- Say you have an option called "Red" in Spanish, that you added since installing CiviCRM
- When enabling this extension, it will assume that "Red" is an English word and try to find a translation in English, updating the option to "Roja".
Luckily, there is no "Red" string in CiviCRM core, so the string will be kept to "Red".
Part of this problem is that CiviCRM configurations are user-defined strings and we do not have a way to distinguish options from the default configuration, from those that are user-defined.
That said, as outlined above, the risk is very small.
Support
Please post bug reports in the issue tracker of this project:
https://lab.civicrm.org/extensions/fixoptiontranslations/-/issues
For commercial support:
https://www.symbiotic.coop/en
Coop Symbiotic is a worker-owned co-operative based in Canada. We have a strong experience working with non-profits and CiviCRM. We provide fast, affordable, turn-key hosting with regular upgrades and proactive monitoring, as well as custom development and training.
For developers/implementors: We offer a collaborative environment that lets you have control on your work while being part of a team. For CiviCRM providers or solo freelancers, we also provide white-label hosting and second-level support.