From d4d4c4e73902705fff4c3d1d3d5c220975830f59 Mon Sep 17 00:00:00 2001
From: qkqpttgf <45693631+qkqpttgf@users.noreply.github.com>
Date: Mon, 13 Jul 2020 17:41:48 +0800
Subject: [PATCH] expire cookie in install
---
platform/TencentSCF.php | 23 ++++++++++++++++++++---
1 file changed, 20 insertions(+), 3 deletions(-)
diff --git a/platform/TencentSCF.php b/platform/TencentSCF.php
index 497d110..14b592b 100644
--- a/platform/TencentSCF.php
+++ b/platform/TencentSCF.php
@@ -135,9 +135,23 @@ function install()
setConfig($tmp);
if (needUpdate()) {
OnekeyUpate();
- return message('update to github version, reinstall.', 'Program updating', 201);
+ return message('update to github version, reinstall.
+
+ ', 'Program updating', 201);
}
- return output('Jump', 302);
+ return output('Jump
+
+ ', 302);
}
if ($_GET['install1']) {
//if ($_POST['admin']!='') {
@@ -219,7 +233,10 @@ language:
';
document.cookie="timezone="+timezone+"; path=/; "+expires;
function changelanguage(str)
{
- document.cookie=\'language=\'+str+\'; path=/\';
+ var expd = new Date();
+ expd.setTime(expd.getTime()+(2*60*60*1000));
+ var expires = "expires="+expd.toGMTString();
+ document.cookie=\'language=\'+str+\'; path=/; \'+expires;
location.href = location.href;
}
function notnull(t)