CMXX - Multisite setup

This commit is contained in:
“VeLiTi”
2025-03-13 12:07:18 +01:00
parent 0b78fa4827
commit 0d6f75704b
26 changed files with 3471 additions and 206 deletions

View File

@@ -1,7 +1,7 @@
<?php
defined(page_security_key) or exit;
// Configuration file
$file = './settings/config.php';
$file = './settings/config_redirector.php';
//Check if allowed
if (isAllowed('settings',$_SESSION['profile'],$_SESSION['permission'],'R') === 0){
@@ -93,7 +93,7 @@ if (isset($_POST['submit']) && !empty($_POST)) {
$v = in_array(strtolower($v), ['true', 'false']) ? strtolower($v) : '\'' . $v . '\'';
$contents = preg_replace('/define\(\'' . $k . '\'\, ?(.*?)\)/s', 'define(\'' . $k . '\',' . $v . ')', $contents);
}
file_put_contents('./settings/config.php', $contents);
file_put_contents('./settings/config_redirector.php', $contents);