use accept_language
parent
23ee2630ef
commit
00023986b3
|
@ -28,6 +28,7 @@ function GetGlobalVariable($event)
|
||||||
|
|
||||||
function GetPathSetting($event, $context)
|
function GetPathSetting($event, $context)
|
||||||
{
|
{
|
||||||
|
$_SERVER['firstacceptlanguage'] = strtolower(splitfirst(splitfirst($event['headers']['accept-language'],';')[0],',')[0]);
|
||||||
$_SERVER['function_name'] = $context['function_name'];
|
$_SERVER['function_name'] = $context['function_name'];
|
||||||
$_SERVER['namespace'] = $context['namespace'];
|
$_SERVER['namespace'] = $context['namespace'];
|
||||||
$host_name = $event['headers']['host'];
|
$host_name = $event['headers']['host'];
|
||||||
|
@ -132,7 +133,6 @@ function install()
|
||||||
setConfig($tmp);
|
setConfig($tmp);
|
||||||
if (needUpdate()) {
|
if (needUpdate()) {
|
||||||
OnekeyUpate();
|
OnekeyUpate();
|
||||||
//updateProgram($_SERVER['function_name'], $_SERVER['Region'], $_SERVER['namespace'], $SecretId, $SecretKey);
|
|
||||||
return message('update to github version, reinstall.<script>document.cookie=\'language=; path=/\';</script><meta http-equiv="refresh" content="3;URL=' . $url . '">', 'Program updating', 201);
|
return message('update to github version, reinstall.<script>document.cookie=\'language=; path=/\';</script><meta http-equiv="refresh" content="3;URL=' . $url . '">', 'Program updating', 201);
|
||||||
}
|
}
|
||||||
return output('Jump<script>document.cookie=\'language=; path=/\';</script><meta http-equiv="refresh" content="3;URL=' . path_format($_SERVER['base_path'] . '/') . '">', 302);
|
return output('Jump<script>document.cookie=\'language=; path=/\';</script><meta http-equiv="refresh" content="3;URL=' . path_format($_SERVER['base_path'] . '/') . '">', 302);
|
||||||
|
|
Loading…
Reference in New Issue