functions.inc.php:

- check_language(): remove things like ";q=0.8" before checking if 
  a language exists


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1547 a1433add-5e2c-0410-b055-b7f2511e0802
pull/2/head
Christian Boltz 11 years ago
parent 4785426269
commit b137e774f6

@ -153,6 +153,7 @@ function check_language ($use_post = 1) {
for($i = 0; $i < count($lang_array); $i++) {
$lang_next = $lang_array[$i];
$lang_next = strtolower(trim($lang_next));
$lang_next = preg_replace('/;.*$/', '', $lang_next); # remove things like ";q=0.8"
if(array_key_exists($lang_next, $supported_languages)) {
$lang = $lang_next;
break;

Loading…
Cancel
Save