Updated script execution path

The shell_exec command in index.php has been updated to include the document root in the script path. This change ensures that the correct script is executed regardless of the current working directory.
This commit is contained in:
Jeroen De Meerleer 2024-06-13 14:33:48 +02:00
parent e4d78e054b
commit b52abb69c7
Signed by: JeroenED
GPG Key ID: 28CCCB8F62BFADD6

View File

@ -2,5 +2,5 @@
header('Content-Type: text/plain; version=0.0.4');
$config = getenv('CONFIG_FILE');
$phpbin = getenv('PHP_BINARY');
$output = shell_exec('CONFIG_FILE="' . $config . '" ' . $phpbin . ' script.php');
$output = shell_exec('CONFIG_FILE="' . $config . '" ' . $phpbin . ' ' . $_SERVER['DOCUMENT_ROOT'] . 'script.php');
echo $output;