@@ 377-388 (lines=12) @@ | ||
374 | * |
|
375 | * @return void |
|
376 | */ |
|
377 | protected function _set_languages() |
|
378 | { |
|
379 | if ((count($this->languages) === 0) && ! empty($_SERVER['HTTP_ACCEPT_LANGUAGE'])) |
|
380 | { |
|
381 | $this->languages = explode(',', preg_replace('/(;\s?q=[0-9\.]+)|\s/i', '', strtolower(trim($_SERVER['HTTP_ACCEPT_LANGUAGE'])))); |
|
382 | } |
|
383 | ||
384 | if (count($this->languages) === 0) |
|
385 | { |
|
386 | $this->languages = array('Undefined'); |
|
387 | } |
|
388 | } |
|
389 | ||
390 | // -------------------------------------------------------------------- |
|
391 | ||
@@ 397-408 (lines=12) @@ | ||
394 | * |
|
395 | * @return void |
|
396 | */ |
|
397 | protected function _set_charsets() |
|
398 | { |
|
399 | if ((count($this->charsets) === 0) && ! empty($_SERVER['HTTP_ACCEPT_CHARSET'])) |
|
400 | { |
|
401 | $this->charsets = explode(',', preg_replace('/(;\s?q=.+)|\s/i', '', strtolower(trim($_SERVER['HTTP_ACCEPT_CHARSET'])))); |
|
402 | } |
|
403 | ||
404 | if (count($this->charsets) === 0) |
|
405 | { |
|
406 | $this->charsets = array('Undefined'); |
|
407 | } |
|
408 | } |
|
409 | ||
410 | // -------------------------------------------------------------------- |
|
411 |