New current_charset() function added.

Merged from MOODLE_16_UTF8. Abandoning the branch.
This commit is contained in:
stronk7 2006-01-05 16:04:26 +00:00
parent 1d5295b62b
commit 46115724f5

View File

@ -4903,6 +4903,26 @@ function get_list_of_languages() {
return $languages;
}
/**
* Returns a list of charset codes. It's hardcoded, so they should be added manually
* (cheking that such charset is supported by the texlib library!)
*
* @return array And associative array with contents in the form of charset => charset
*/
function get_list_of_charsets() {
$charsets = array(
'EUC-JP' => 'EUC-JP',
'ISO-2022-JP'=> 'ISO-2022-JP',
'ISO-8859-1' => 'ISO-8859-1',
'SHIFT-JIS' => 'SHIFT-JIS',
'UTF-8' => 'UTF-8');
asort($charsets);
return $charsets;
}
/**
* Returns a list of country names in the current language
*