Revision 1986
Added by Dietmar about 11 years ago
settings.php | ||
---|---|---|
605 | 605 |
} |
606 | 606 |
|
607 | 607 |
/*-- show language select box ----------------------------------------------------------*/ |
608 |
$sql = 'SELECT `directory`, `name` FROM `'.TABLE_PREFIX.'addons` ' |
|
609 |
. 'WHERE `type`=\'language\' '; |
|
610 |
if( !defined('PAGE_LANGUAGES') || !PAGE_LANGUAGES) { |
|
611 |
// display only default and current language if site is single language only |
|
612 |
$sql .= 'AND `directory`=\''.DEFAULT_LANGUAGE.'\' '; |
|
613 |
if($aCurrentPage['language'] != DEFAULT_LANGUAGE) { |
|
614 |
$sql .= 'AND `directory`=\''.$aCurrentPage['language'].'\' '; |
|
615 |
} |
|
616 |
} |
|
617 |
$sql .= 'ORDER BY `name`'; |
|
618 |
if( ($oLanguages = $database->query($sql)) ) |
|
608 |
|
|
609 |
if( ($oLanguages = $admin->getAvailableLanguagesObjectInstance()) ) |
|
619 | 610 |
{ |
620 | 611 |
$aAvailLanguages = array(); |
621 | 612 |
while($aLanguage = $oLanguages->fetchRow(MYSQL_ASSOC)) { |
Also available in: Unified diff
! If the advanced option languages Page was disabled or pages exist with one language only,
then all available languages are shown to be selected in the User-Settings implemented in backend