Allow installation on sub directories #26

Merged
amit177 merged 2 commits from bugfix/installation-path into main 2023-09-10 20:22:56 +08:00
2 changed files with 3 additions and 3 deletions

View File

@ -31,7 +31,7 @@ function exitErrorMessage(string $message): void
function exitNormal(): void
{
header('Location: /');
header("Refresh: 0");
exit;
}

View File

@ -182,7 +182,7 @@ $templateData['csrfToken'] = $_SESSION[LookingGlass::SESSION_CSRF] = bin2hex(ran
<div class="card shadow-lg">
<div class="card-body p-3">
<h1 class="fs-4 card-title mb-4">Looking Glass</h1>
<form method="POST" action="/" autocomplete="off">
<form method="POST" autocomplete="off">
<input type="hidden" name="csrfToken" value="<?php echo $templateData['csrfToken'] ?>">
<div class="row">
@ -286,7 +286,7 @@ $templateData['csrfToken'] = $_SESSION[LookingGlass::SESSION_CSRF] = bin2hex(ran
outputCard.style.display = 'inherit'
fetch('/backend.php')
fetch('backend.php')
.then(async (response) => {
// response.body is a ReadableStream
const reader = response.body.getReader()