log messages

This commit is contained in:
HB9HIL
2024-07-22 15:09:07 +02:00
parent ed59ce9b02
commit 3f40c62be3
10 changed files with 124 additions and 27 deletions

View File

@@ -59,6 +59,8 @@ $language = $_COOKIE[$gt_conf['lang_cookie']];
// and set the locale for gettext
T_setlocale(LC_MESSAGES, $language);
$websiteurl = $http_scheme . '://' . str_replace("index.php", "", $_SERVER['HTTP_HOST'] . str_replace("/install/", "", $_SERVER['REQUEST_URI'])) . '/';
?>
<!DOCTYPE html>
<html lang="<?= $language; ?>">
@@ -67,7 +69,7 @@ T_setlocale(LC_MESSAGES, $language);
function log_message(level, message) {
$.ajax({
type: 'POST',
url: 'index.php',
url: 'ajax.php',
data: {
write_to_logfile: 1,
log_level: level,

View File

@@ -42,8 +42,20 @@ if ($_POST['write_to_logfile'] ?? false == true) {
*
*/
// config_file()
if ($_POST['check_lockfile'] ?? false == true) {
$lockfile = '../install/.lock';
if (file_exists($lockfile)) {
$result = 'installer_locked';
} else {
$result = 'no_lockfile';
}
echo $result;
exit;
}
// config_file()
if ($_POST['run_config_file'] ?? false == true) {
sleep(1);
$data = $_POST['data'];