diff options
author | Romain d'Alverny <rda@mageia.org> | 2010-12-06 09:01:19 +0000 |
---|---|---|
committer | Romain d'Alverny <rda@mageia.org> | 2010-12-06 09:01:19 +0000 |
commit | 8a851df7c1ed5c982368e0bc6e3c564b1cc40b84 (patch) | |
tree | 3d73661e7bbebf5a9000a4ef2f4708feca474b44 /langs.php | |
parent | 349b9d6adaefff65a03eeafde1ee524dd0dd1f99 (diff) | |
download | www-8a851df7c1ed5c982368e0bc6e3c564b1cc40b84.tar www-8a851df7c1ed5c982368e0bc6e3c564b1cc40b84.tar.gz www-8a851df7c1ed5c982368e0bc6e3c564b1cc40b84.tar.bz2 www-8a851df7c1ed5c982368e0bc6e3c564b1cc40b84.tar.xz www-8a851df7c1ed5c982368e0bc6e3c564b1cc40b84.zip |
localize top menu
Diffstat (limited to 'langs.php')
-rw-r--r-- | langs.php | 41 |
1 files changed, 34 insertions, 7 deletions
@@ -32,22 +32,49 @@ foreach ($langs as $k => $v) // global nav $nav_list = array( "/{$locale}/" => 'Mageia', - "http://blog.mageia.org/{$locale}" => 'Blog', + "http://blog.mageia.org/{$locale}" => array( + 'en' => 'Blog', + 'tr' => 'Web Günlüğü' + ), '/wiki' => 'Wiki', - "/{$locale}/faq/" => 'FAQ', - "http://donate.mageia.org/{$locale}/" => 'Donations', - "http://mageia.org/wiki/doku.php?id=press" => 'Press', - "/{$locale}/about/values/" => 'Values', - "/{$locale}/about/code-of-conduct/" => 'Code of Conduct' + "/{$locale}/faq/" => array( + 'en' => 'FAQ', + 'tr' => 'S.S.S.' + ), + "http://donate.mageia.org/{$locale}/" => array( + 'en' => 'Donations', + 'fr' => 'Dons', + 'tr' => 'Bağışlar' + ), + "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' + ), + "/{$locale}/about/code-of-conduct/" => array( + 'en' => 'Code of Conduct', + 'fr' => 'Code de conduite', + 'tr' => 'Temel İlkeler' + ) ); $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('<a href="%s"%s>%s</a>', $k, $k == $sru ? ' class="sel"' : '', - $v); + $title); } echo sprintf('<div class="nav"><!--googleoff: all--><div class="nav2"><p class="loc">%s</p>', implode(' | ', $list_menu)); |