Bernd Wurst commited on 2024-09-03 19:24:24
Zeige 3 geänderte Dateien mit 8 Einfügungen und 6 Löschungen.
... | ... |
@@ -47,12 +47,12 @@ if (substr($number, 0, 5) == '+49 1' && isset($_SESSION['mode']) && $_SESSION['m |
47 | 47 |
</div> |
48 | 48 |
'; |
49 | 49 |
}*/ |
50 |
-$modeparam = '?mode=local'; |
|
50 |
+$mode = 'remote'; |
|
51 | 51 |
if (isset($_SESSION['mode'])) { |
52 |
- $modeparam = "?mode={$_SESSION['mode']}"; |
|
52 |
+ $mode = $_SESSION['mode']; |
|
53 | 53 |
} |
54 | 54 |
$content .=' <div class="form-group form-group-lg"> |
55 |
- <div><a class="btn btn-primary btn-lg" href="clear.php'.$modeparam.'">Zurück zum Anfang</a></div> |
|
55 |
+ <div><a class="btn btn-primary btn-lg" href="clear.php?mode='.$mode.'">Zurück zum Anfang</a></div> |
|
56 | 56 |
</div> |
57 | 57 |
'; |
58 | 58 |
|
... | ... |
@@ -60,4 +60,6 @@ include("template.php"); |
60 | 60 |
|
61 | 61 |
# Session-Daten löschen weil Änderungen jetzt nicht mehr möglich sein sollen |
62 | 62 |
session_destroy(); |
63 |
+session_start(); |
|
63 | 64 |
|
65 |
+$_SESSION['mode'] = $mode; |
... | ... |
@@ -16,8 +16,8 @@ if (isset($_SESSION['last_activity']) && $_SESSION['last_activity'] < time()-(20 |
16 | 16 |
$filename = "../data/".date('Y').'/'.time().'-canceledsession-'.$_SESSION['orderid'].'.json'; |
17 | 17 |
} |
18 | 18 |
@file_put_contents($filename, json_encode($_SESSION)); |
19 |
- session_destroy(); |
|
20 |
- session_start(); |
|
19 |
+ header('Location: clear.php'); |
|
20 |
+ die(); |
|
21 | 21 |
} |
22 | 22 |
} |
23 | 23 |
$_SESSION['last_activity'] = time(); |
24 | 24 |