diff options
-rw-r--r-- | 1/notes/notes.php | 12 | ||||
-rw-r--r-- | en/1/for-you/index.php | 12 | ||||
-rw-r--r-- | en/1/next/index.php | 14 |
3 files changed, 13 insertions, 25 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> diff --git a/en/1/for-you/index.php b/en/1/for-you/index.php index 360b7e8f9..e22798f59 100644 --- a/en/1/for-you/index.php +++ b/en/1/for-you/index.php @@ -1,14 +1,10 @@ <?php -$locale = explode('/', $_SERVER['REQUEST_URI']); -$locale = $locale[1]; - +define('HLANG', true); +require '../../../langs.php'; require 'locales.php'; -if (!array_key_exists($locale, $_t)) { - $locale = 'en'; -} -$_t = $_t[$locale]; +$_t = i18n::get_strings($_t, $locale, $i18n_fallback_rules); ?> <!DOCTYPE html> @@ -23,7 +19,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></div> diff --git a/en/1/next/index.php b/en/1/next/index.php index f45b71ef6..187f0b548 100644 --- a/en/1/next/index.php +++ b/en/1/next/index.php @@ -1,14 +1,10 @@ <?php -$locale = explode('/', $_SERVER['REQUEST_URI']); -$locale = $locale[1]; +define('HLANG', true); +require '../../../langs.php'; +include 'locales.php'; -require 'locales.php'; -if (!array_key_exists($locale, $_t)) { - $locale = 'en'; -} - -$_t = $_t[$locale]; +$_t = i18n::get_strings($_t, $locale, $i18n_fallback_rules); ?> @@ -25,7 +21,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> |