0 ? implode('/', $sel) : null; $list_langs = array(); $options = array(); foreach ($langs as $k => $v) { $list_langs[] = sprintf('%s', $page != null ? implode('/', array($k, $page)) : $k, $k == $locale ? ' class="sel"' : '', $v); $options[] = sprintf('', $k, $k == $locale ? ' selected="selected"' : '', $v); } // global nav $nav_list = array( "/{$locale}/" => 'Mageia', "http://blog.mageia.org/{$locale}" => array( 'en' => 'Blog', 'tr' => 'Web Günlüğü' ), '/wiki' => 'Wiki', "/{$locale}/faq/" => array( 'en' => 'FAQ', 'tr' => 'S.S.S.', 'ro' => 'Întrebări frecvente' ), "http://donate.mageia.org/{$locale}/" => array( 'en' => 'Donations', 'fr' => 'Dons', 'tr' => 'Bağışlar', 'ro' => 'Donații' ), "http://mageia.org/wiki/doku.php?id=press" => array( 'en' => 'Press', 'fr' => 'Presse', 'tr' => 'Basın' ), "/{$locale}/about/values/" => array( 'en' => 'Values', 'fr' => 'Valeurs', 'tr' => 'Değerler', 'ro' => 'Valori' ), "/{$locale}/about/code-of-conduct/" => array( 'en' => 'Code of Conduct', 'fr' => 'Code de conduite', 'tr' => 'Temel İlkeler', 'ro' => 'Codul de conduită' ) ); $list_menu = array(); foreach ($nav_list as $k => $v) { if (is_array($v)) $title = array_key_exists($locale, $v) ? $v[$locale] : $v['en']; else $title = $v; $list_menu[] = sprintf('%s', $k, $k == $sru ? ' class="sel"' : '', $title); } echo sprintf('
H; /* echo sprintf('%s
', implode(' | ', $list_langs)); */