Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-17662

Cannot use Russian or Ukranian translations with native gettext

    Details

    • Type: Bug
    • Status: Won't Do
    • Priority: Minor
    • Resolution: Won't Do
    • Affects Version/s: 4.6.10
    • Fix Version/s: None
    • Component/s: Internationalisation
    • Labels:
    • Versioning Impact:
      Patch (backwards-compatible bug fixes)
    • Documentation Required?:
      None
    • Funding Source:
      Needs Funding

      Description

      I get the following notices, and translation don't work for certain languages:

      Notice: Undefined index: ru in CRM_Core_I18n_PseudoConstant::longForShort()

      I've only seen this affect Russian (ru_RU) and Ukranian (uk_UA), but my sample size was only 5, so I suspect this is broader.

      I fixed this locally by adding the following lines to `longForShortMapping()` in `sites/all/modules/civicrm/CRM/Core/I18n/PseudoConstant.php`:

          $longForShortMapping['ru'] = 'ru_RU';
          $longForShortMapping['uk'] = 'uk_UA';

        Attachments

          Activity

            People

            • Assignee:
              mlutfy Mathieu Lutfy
              Reporter:
              ergonlogic Christopher Gervais
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: