4 require_once
'Services/Language/classes/class.ilLanguage.php';
5 require_once
'Services/Language/classes/class.ilLanguageDetectorFactory.php';
30 public function detect()
38 $detected_language = $installed_languages[0];
40 foreach($this->factory->getValidInstances() as $detector)
44 $language = $detector->getIso2LanguageCode();
45 if(in_array($language, $installed_languages))
47 $detected_language = $language;
52 $ilLog->write(__METHOD__ .
' ' . $e->getMessage());
56 return $detected_language;
Class ilLanguageDetectorFactory.
Class for language related exception handling in ILIAS.
Class ilLanguageDetection.
static _getInstalledLanguages()