+ fix setClientLang method for ie6

This commit is contained in:
wangyidong
2011-04-30 02:08:26 +00:00
parent 0c938eb8d0
commit 49013f36c2

View File

@@ -679,7 +679,14 @@ class router
}
elseif(isset($_SERVER['HTTP_ACCEPT_LANGUAGE']))
{
$this->clientLang = substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, strpos($_SERVER['HTTP_ACCEPT_LANGUAGE'], ','));
if(strpos($_SERVER['HTTP_ACCEPT_LANGUAGE'], ',') === false)
{
$this->clientLang = $_SERVER['HTTP_ACCEPT_LANGUAGE'];
}
else
{
$this->clientLang = substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, strpos($_SERVER['HTTP_ACCEPT_LANGUAGE'], ','));
}
}
if(!empty($this->clientLang))
{