add support for multiple languages

This commit is contained in:
oliver 2015-04-26 11:15:38 +02:00
commit 3fdb23374c
4 changed files with 126 additions and 35 deletions

View file

@ -184,6 +184,22 @@
{
return $_SERVER['REQUEST_METHOD'];
}
/**
* Get languages from browser setting.
*
* @return string Browser setting for accepted languages.
*/
public function getBrowserLanguages()
{
if(array_key_exists('HTTP_ACCEPT_LANGUAGE', $_SERVER)) {
return $_SERVER['HTTP_ACCEPT_LANGUAGE'];
}
return null;
}
/**