33 lines
857 B
PHP
33 lines
857 B
PHP
<?php
|
|
/** @var ?array $HOME the home directory on the server (defined via bootstraping) */
|
|
require_once "config.php";
|
|
|
|
if (!isset($HOME)) {
|
|
die("Missing HOME config!");
|
|
}
|
|
|
|
$CONFIG = json_decode(
|
|
json: file_get_contents(filename: join("/", [$HOME, ".local/config.json"])),
|
|
associative: true,
|
|
);
|
|
|
|
$SECRETS = json_decode(
|
|
json: file_get_contents(
|
|
filename: join("/", [$HOME, "/.local/secrets.json"]),
|
|
),
|
|
associative: true,
|
|
);
|
|
|
|
setlocale(LC_ALL, "de_DE@euro", "de_DE", "de", "ge");
|
|
$BASE_PATH = join("/", [$HOME, $CONFIG["cwsvJudo"]["http"]["serve_dir"]]);
|
|
set_include_path(
|
|
implode(PATH_SEPARATOR, [
|
|
get_include_path(),
|
|
$BASE_PATH,
|
|
join("/", [$BASE_PATH, "ressourcen"]),
|
|
join("/", [$BASE_PATH, "ressourcen", "phpLib"]),
|
|
join("/", [$HOME, "libs", "php"]),
|
|
"./lib/",
|
|
]),
|
|
);
|