| @@ 69-79 (lines=11) @@ | ||
| 66 | if (preg_match_all($re, $acceptLanguage, $matches)) { |
|
| 67 | $otherlangs=array(); |
|
| 68 | $otherq=false; |
|
| 69 | foreach ($matches as $match) { |
|
| 70 | if (!isset($match[2])) { |
|
| 71 | $match[2]=1; |
|
| 72 | } |
|
| 73 | if ($match[1]=="*") { |
|
| 74 | $otherq=$match[2]; |
|
| 75 | } else if ($nls->available[$match[1]]) { |
|
| 76 | $otherlangs[]=$match[1]; |
|
| 77 | $nls->accepted[$match[1]]=$match[2]; |
|
| 78 | } |
|
| 79 | } |
|
| 80 | if ($otherq !== false) { |
|
| 81 | $otherlangs=array_diff(array_keys($nls->available), $otherlangs); |
|
| 82 | foreach ($otherlangs as $lang) { |
|
| @@ 798-808 (lines=11) @@ | ||
| 795 | $ARCurrent->acceptlang=array(); |
|
| 796 | $otherlangs=array(); |
|
| 797 | $otherq=false; |
|
| 798 | foreach ($regs as $reg) { |
|
| 799 | if (!isset($reg[2])) { |
|
| 800 | $reg[2]=1; |
|
| 801 | } |
|
| 802 | if ($reg[1]=="*") { |
|
| 803 | $otherq=$reg[2]; |
|
| 804 | } else if ($AR->nls->list[$reg[1]]) { |
|
| 805 | $otherlangs[]=$reg[1]; |
|
| 806 | $ARCurrent->acceptlang[$reg[1]]=$reg[2]; |
|
| 807 | } |
|
| 808 | } |
|
| 809 | if ($otherq !== false) { |
|
| 810 | $otherlangs=array_diff(array_keys($AR->nls->list), $otherlangs); |
|
| 811 | foreach ($otherlangs as $lang) { |
|