diff options
Diffstat (limited to 'engine/lib')
-rw-r--r-- | engine/lib/languages.php | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/engine/lib/languages.php b/engine/lib/languages.php index 781fe2e6e..973309cb9 100644 --- a/engine/lib/languages.php +++ b/engine/lib/languages.php @@ -94,6 +94,21 @@ else error_log("Missing translation path $path");
}
+ + /** + * Return an array of installed translations as an associative array "two letter code" => "native language name". + */ + function get_installed_translations() + { + global $CONFIG; + + $installed = array(); + + foreach ($CONFIG->translations as $k => $v) + $installed[$k] = elgg_echo($k, $k); + + return $installed; + } register_translations(dirname(dirname(dirname(__FILE__))) . "/languages/");
|