aboutsummaryrefslogtreecommitdiffstats
path: root/1
diff options
context:
space:
mode:
authorRomain d'Alverny <rda@mageia.org>2011-06-10 17:48:33 +0000
committerRomain d'Alverny <rda@mageia.org>2011-06-10 17:48:33 +0000
commit2a690564a8c0adc80a3ff33316f18204ac08cdbb (patch)
tree91dd073813e0492b62737e6729a0bb1ee0f95d03 /1
parentb1fbb2e8e435a2b2ff13ca76db4013ca030f396c (diff)
downloadwww-2a690564a8c0adc80a3ff33316f18204ac08cdbb.tar
www-2a690564a8c0adc80a3ff33316f18204ac08cdbb.tar.gz
www-2a690564a8c0adc80a3ff33316f18204ac08cdbb.tar.bz2
www-2a690564a8c0adc80a3ff33316f18204ac08cdbb.tar.xz
www-2a690564a8c0adc80a3ff33316f18204ac08cdbb.zip
simplify i18n strings mgmt, factor some code, show nav in a different way
Diffstat (limited to '1')
-rw-r--r--1/notes/notes.php12
1 files changed, 4 insertions, 8 deletions
diff --git a/1/notes/notes.php b/1/notes/notes.php
index 84290618b..62bc6ab3b 100644
--- a/1/notes/notes.php
+++ b/1/notes/notes.php
@@ -1,14 +1,10 @@
<?php
-$locale = explode('/', $_SERVER['REQUEST_URI']);
-$locale = $locale[1];
-
+define('HLANG', true);
+require '../../../langs.php';
require 'notes_locales.php';
-if (!array_key_exists($locale, $_t)) {
- $locale = 'en';
-}
-$_t = $_t[$locale];
+$_t = i18n::get_strings($_t, $locale, $i18n_fallback_rules);
?>
<!DOCTYPE html>
@@ -24,7 +20,7 @@ $_t = $_t[$locale];
<?php include '../../../analytics.php'; ?>
</head>
<body class="release">
- <?php include '../../../langs.php'; ?>
+ <?php echo $hsnav; ?>
<div id="doc" class="yui-t7">
<div id="hd" role="banner">
<h1><a id="logo" href="/"><span>Mageia</span></a> <span class="lsep">|</span> <span class="subh"><?php echo $_t['page_h1']; ?></span></h1>