moodle/auth/cas/languages.php
Inaki fcf46da1c5 auth/ldap cas/ldap MDL-23371 auth/ldap and auth/cas refactor
They now share most of the code again, this time via subclassing, and they
share some code with enrol/ldap. They have also gained some features and a few
fixes.
2010-07-25 22:36:15 +00:00

16 lines
401 B
PHP

<?php
$caslangprefix = 'PHPCAS_LANG_';
$CASLANGUAGES = array ();
$consts = get_defined_constants(true);
foreach ($consts['user'] as $key => $value) {
if (substr($key, 0, strlen($caslangprefix)) == $caslangprefix) {
$CASLANGUAGES[$value] = $value;
}
}
if (empty($CASLANGUAGES)) {
$CASLANGUAGES = array ('english' => 'english',
'french' => 'french');
}