mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-19 19:15:22 +00:00
move system_get_language_code into head.inc
This commit is contained in:
parent
b4d06b803d
commit
ccb05e3b6d
@ -1,5 +1,19 @@
|
||||
<?php
|
||||
|
||||
function system_get_language_code() {
|
||||
global $config;
|
||||
|
||||
// a language code, as per [RFC3066]
|
||||
$language = $config['system']['language'];
|
||||
$code = str_replace("_", "-", $language);
|
||||
|
||||
if (empty($code))
|
||||
$code = "en-US"; // Set default code.
|
||||
|
||||
return $code;
|
||||
}
|
||||
|
||||
|
||||
$g['theme'] = get_current_theme();
|
||||
|
||||
$pagetitle = gentitle( $pgtitle );
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user