diff options
author | Romain d'Alverny <rda@mageia.org> | 2010-10-22 08:14:44 +0000 |
---|---|---|
committer | Romain d'Alverny <rda@mageia.org> | 2010-10-22 08:14:44 +0000 |
commit | 40c0258381108d04f4e2a91713724849ad78ad3c (patch) | |
tree | 6cbd6615a9738191b3b71eec73bed9e94204d3d2 /index.php | |
parent | 6c45f844e892cd54fb2baccd4b4fa9050b2512db (diff) | |
download | www-40c0258381108d04f4e2a91713724849ad78ad3c.tar www-40c0258381108d04f4e2a91713724849ad78ad3c.tar.gz www-40c0258381108d04f4e2a91713724849ad78ad3c.tar.bz2 www-40c0258381108d04f4e2a91713724849ad78ad3c.tar.xz www-40c0258381108d04f4e2a91713724849ad78ad3c.zip |
redirect root access after browser lang prefs
Diffstat (limited to 'index.php')
-rw-r--r-- | index.php | 13 |
1 files changed, 12 insertions, 1 deletions
@@ -1 +1,12 @@ -<?php header('Location: /en/'); die;
\ No newline at end of file +<?php +/** +*/ + +require_once 'langs.inc.php'; +require_once 'localeDetection.class.php'; + +$locale = new ChooseLocale(array_keys($langs)); + +$locale->setDefaultLocale('en'); + +header(sprintf('Location: /%s/', $locale->getCompatibleLocale()));
\ No newline at end of file |