Skip to content
Snippets Groups Projects
Commit c78e9dd9 authored by Andreas Åkre Solberg's avatar Andreas Åkre Solberg
Browse files

Add template parameter to header to optionally hide language bar..

git-svn-id: https://simplesamlphp.googlecode.com/svn/trunk@1065 44740490-163a-0410-bde0-09ae8108e29a
parent 8954a20f
No related branches found
No related tags found
No related merge requests found
......@@ -44,31 +44,40 @@ if($onLoad !== '') {
?></a></h1>
</div>
<div id="languagebar">
<?php
$languages = $this->getLanguageList();
$langnames = array(
'no' => 'Bokmål',
'nn' => 'Nynorsk',
'se' => 'Sámi',
'da' => 'Dansk',
'en' => 'English',
'de' => 'Deutsch',
'sv' => 'Svenska',
'fi' => 'Suomeksi',
'es' => 'Español',
'fr' => 'Français',
'nl' => 'Nederlands',
'lb' => 'Luxembourgish',
'sl' => 'Slovenščina', // Slovensk
'hr' => 'Hrvatski', // Croatian
'hu' => 'Magyar', // Hungarian
'pt' => 'Português', // Portuguese
'pt-BR' => 'Português brasileiro', // Portuguese
);
$includeLanguageBar = TRUE;
if (!empty($_POST))
$includeLanguageBar = FALSE;
if (isset($this->data['hideLanguageBar']) && $this->data['hideLanguageBar'] === TRUE)
$includeLanguageBar = FALSE;
if (empty($_POST) ) {
if ($includeLanguageBar) {
echo '<div id="languagebar">';
$languages = $this->getLanguageList();
$langnames = array(
'no' => 'Bokmål',
'nn' => 'Nynorsk',
'se' => 'Sámi',
'da' => 'Dansk',
'en' => 'English',
'de' => 'Deutsch',
'sv' => 'Svenska',
'fi' => 'Suomeksi',
'es' => 'Español',
'fr' => 'Français',
'nl' => 'Nederlands',
'lb' => 'Luxembourgish',
'sl' => 'Slovenščina', // Slovensk
'hr' => 'Hrvatski', // Croatian
'hu' => 'Magyar', // Hungarian
'pt' => 'Português', // Portuguese
'pt-BR' => 'Português brasileiro', // Portuguese
);
$textarray = array();
foreach ($languages AS $lang => $current) {
if ($current) {
......@@ -79,8 +88,9 @@ if($onLoad !== '') {
}
}
echo join(' | ', $textarray);
echo '</div>';
}
?>
</div>
<div id="content">
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment