From Piotr, a GSOC student for us, who needs a way to get unfiltered language list
This commit is contained in:
@@ -156,31 +156,12 @@ function PMA_langDetect(&$str, $envType)
|
|||||||
} // end of the 'PMA_langDetect()' function
|
} // end of the 'PMA_langDetect()' function
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @global string path to the translations directory
|
* Returns list of languages supported by phpMyAdmin
|
||||||
|
*
|
||||||
|
* @return array
|
||||||
*/
|
*/
|
||||||
$GLOBALS['lang_path'] = './lang/';
|
function PMA_langList()
|
||||||
|
{
|
||||||
/**
|
|
||||||
* @global string interface language
|
|
||||||
*/
|
|
||||||
$GLOBALS['lang'] = 'en-utf-8';
|
|
||||||
/**
|
|
||||||
* @global boolean wether loading lang from cfg failed
|
|
||||||
*/
|
|
||||||
$GLOBALS['lang_failed_cfg'] = false;
|
|
||||||
/**
|
|
||||||
* @global boolean wether loading lang from cookie failed
|
|
||||||
*/
|
|
||||||
$GLOBALS['lang_failed_cookie'] = false;
|
|
||||||
/**
|
|
||||||
* @global boolean wether loading lang from user request failed
|
|
||||||
*/
|
|
||||||
$GLOBALS['lang_failed_request'] = false;
|
|
||||||
/**
|
|
||||||
* @global string text direction ltr or rtl
|
|
||||||
*/
|
|
||||||
$GLOBALS['text_dir'] = 'ltr';
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* All the supported languages have to be listed in the array below.
|
* All the supported languages have to be listed in the array below.
|
||||||
* 1. The key must be the "official" ISO 639 language code and, if required,
|
* 1. The key must be the "official" ISO 639 language code and, if required,
|
||||||
@@ -208,10 +189,7 @@ $GLOBALS['text_dir'] = 'ltr';
|
|||||||
* example.
|
* example.
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
/**
|
return array(
|
||||||
* @global array supported languages
|
|
||||||
*/
|
|
||||||
$GLOBALS['available_languages'] = array(
|
|
||||||
'af-utf-8' => array('af|afrikaans', 'afrikaans-utf-8', 'af', ''),
|
'af-utf-8' => array('af|afrikaans', 'afrikaans-utf-8', 'af', ''),
|
||||||
'ar-utf-8' => array('ar|arabic', 'arabic-utf-8', 'ar', 'العربية'),
|
'ar-utf-8' => array('ar|arabic', 'arabic-utf-8', 'ar', 'العربية'),
|
||||||
'az-utf-8' => array('az|azerbaijani', 'azerbaijani-utf-8', 'az', 'Azərbaycanca'),
|
'az-utf-8' => array('az|azerbaijani', 'azerbaijani-utf-8', 'az', 'Azərbaycanca'),
|
||||||
@@ -268,6 +246,38 @@ $GLOBALS['available_languages'] = array(
|
|||||||
'zhtw-utf-8' => array('zh[-_](tw|hk)|chinese traditional', 'chinese_traditional-utf-8', 'zh-TW', '中文'),
|
'zhtw-utf-8' => array('zh[-_](tw|hk)|chinese traditional', 'chinese_traditional-utf-8', 'zh-TW', '中文'),
|
||||||
'zh-utf-8' => array('zh|chinese simplified', 'chinese_simplified-utf-8', 'zh', '中文'),
|
'zh-utf-8' => array('zh|chinese simplified', 'chinese_simplified-utf-8', 'zh', '中文'),
|
||||||
);
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @global string path to the translations directory
|
||||||
|
*/
|
||||||
|
$GLOBALS['lang_path'] = './lang/';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @global string interface language
|
||||||
|
*/
|
||||||
|
$GLOBALS['lang'] = 'en-utf-8';
|
||||||
|
/**
|
||||||
|
* @global boolean wether loading lang from cfg failed
|
||||||
|
*/
|
||||||
|
$GLOBALS['lang_failed_cfg'] = false;
|
||||||
|
/**
|
||||||
|
* @global boolean wether loading lang from cookie failed
|
||||||
|
*/
|
||||||
|
$GLOBALS['lang_failed_cookie'] = false;
|
||||||
|
/**
|
||||||
|
* @global boolean wether loading lang from user request failed
|
||||||
|
*/
|
||||||
|
$GLOBALS['lang_failed_request'] = false;
|
||||||
|
/**
|
||||||
|
* @global string text direction ltr or rtl
|
||||||
|
*/
|
||||||
|
$GLOBALS['text_dir'] = 'ltr';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @global array supported languages
|
||||||
|
*/
|
||||||
|
$GLOBALS['available_languages'] = PMA_langList();
|
||||||
|
|
||||||
// Language filtering support
|
// Language filtering support
|
||||||
if (! empty($GLOBALS['cfg']['FilterLanguages'])) {
|
if (! empty($GLOBALS['cfg']['FilterLanguages'])) {
|
||||||
|
Reference in New Issue
Block a user