Spaces:
Sleeping
Sleeping
Update templates/redirect_page.html
Browse files- templates/redirect_page.html +22 -10
templates/redirect_page.html
CHANGED
@@ -1,5 +1,3 @@
|
|
1 |
-
|
2 |
-
|
3 |
<!DOCTYPE html>
|
4 |
<html lang="en">
|
5 |
<head>
|
@@ -7,18 +5,32 @@
|
|
7 |
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
8 |
<title>Logging Out...</title>
|
9 |
<script type="text/javascript">
|
10 |
-
//
|
11 |
-
|
12 |
-
|
13 |
-
|
14 |
-
// Optionally, you can redirect the current tab too:
|
15 |
-
// window.location.href = 'https://www.example.com';
|
16 |
-
|
17 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
18 |
</script>
|
19 |
</head>
|
20 |
<body>
|
21 |
<h1>Logging out...</h1>
|
22 |
<p>Please wait while we log you out and redirect you.</p>
|
23 |
</body>
|
24 |
-
</html>
|
|
|
|
|
|
|
1 |
<!DOCTYPE html>
|
2 |
<html lang="en">
|
3 |
<head>
|
|
|
5 |
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
6 |
<title>Logging Out...</title>
|
7 |
<script type="text/javascript">
|
8 |
+
// Function to get query parameter value from URL
|
9 |
+
function getQueryParam(param) {
|
10 |
+
let urlParams = new URLSearchParams(window.location.search);
|
11 |
+
return urlParams.get(param);
|
|
|
|
|
|
|
12 |
}
|
13 |
+
|
14 |
+
window.onload = function() {
|
15 |
+
// Get table number from the URL
|
16 |
+
let tableNumber = getQueryParam("table");
|
17 |
+
|
18 |
+
// Construct the logout redirect URL with table number
|
19 |
+
let redirectURL = "https://biryanihub-dev-ed.develop.my.salesforce-sites.com/";
|
20 |
+
if (tableNumber) {
|
21 |
+
redirectURL += "?table=" + encodeURIComponent(tableNumber);
|
22 |
+
}
|
23 |
+
|
24 |
+
// Open the new page with the table number
|
25 |
+
window.open(redirectURL, "_blank");
|
26 |
+
|
27 |
+
// Optionally, also redirect the current tab:
|
28 |
+
// window.location.href = redirectURL;
|
29 |
+
};
|
30 |
</script>
|
31 |
</head>
|
32 |
<body>
|
33 |
<h1>Logging out...</h1>
|
34 |
<p>Please wait while we log you out and redirect you.</p>
|
35 |
</body>
|
36 |
+
</html>
|