mirror of
https://github.com/moodle/moodle.git
synced 2025-03-14 12:40:01 +01:00
Forgot to check this in ... has a new function
This commit is contained in:
parent
fbfc267591
commit
82196932b0
@ -1370,13 +1370,36 @@ function get_list_of_countries() {
|
||||
}
|
||||
}
|
||||
|
||||
include("$CFG->dirroot/lang/$lang/countries.php");
|
||||
include_once("$CFG->dirroot/lang/$lang/countries.php");
|
||||
|
||||
asort($string);
|
||||
|
||||
return $string;
|
||||
}
|
||||
|
||||
function get_list_of_pixnames() {
|
||||
/// Returns a list of picture names in the current language
|
||||
global $CFG;
|
||||
|
||||
$lang = current_language();
|
||||
|
||||
if (!file_exists("$CFG->dirroot/lang/$lang/pix.php")) {
|
||||
if ($parentlang = get_string("parentlanguage")) {
|
||||
if (file_exists("$CFG->dirroot/lang/$parentlang/pix.php")) {
|
||||
$lang = $parentlang;
|
||||
} else {
|
||||
$lang = "en"; // countries.php must exist in this pack
|
||||
}
|
||||
} else {
|
||||
$lang = "en"; // countries.php must exist in this pack
|
||||
}
|
||||
}
|
||||
|
||||
include_once("$CFG->dirroot/lang/$lang/pix.php");
|
||||
|
||||
return $string;
|
||||
}
|
||||
|
||||
function document_file($file, $include=true) {
|
||||
/// Can include a given document file (depends on second
|
||||
/// parameter) or just return info about it
|
||||
|
Loading…
x
Reference in New Issue
Block a user