You are here

function lingotek_lookup_language_by_locale in Lingotek Translation 7.2

Same name and namespace in other branches
  1. 7.7 lingotek.util.inc \lingotek_lookup_language_by_locale()
  2. 7.3 lingotek.util.inc \lingotek_lookup_language_by_locale()
  3. 7.4 lingotek.util.inc \lingotek_lookup_language_by_locale()
  4. 7.5 lingotek.util.inc \lingotek_lookup_language_by_locale()
  5. 7.6 lingotek.util.inc \lingotek_lookup_language_by_locale()
1 call to lingotek_lookup_language_by_locale()
lingotek_add_target_language in ./lingotek.util.inc
Adds the target language as being enabled.

File

./lingotek.util.inc, line 734
Utility functions.

Code

function lingotek_lookup_language_by_locale($lingotek_locale) {
  $languages = language_list();
  foreach ($languages as $language) {
    if (isset($language->lingotek_locale) && strcmp($language->lingotek_locale, $lingotek_locale) == 0) {
      return $language;
    }
  }
  return FALSE;
}