From 66df795d25e56e81a44d601f5b25da2d07562576 Mon Sep 17 00:00:00 2001 From: Miraty Date: Sat, 10 Feb 2024 14:07:47 +0100 Subject: [PATCH] Use realpath for ROOT to allow symlinks to mkht.php --- mkht.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mkht.php b/mkht.php index 12ede3e..518ac66 100755 --- a/mkht.php +++ b/mkht.php @@ -5,7 +5,7 @@ if (php_sapi_name() !== 'cli') umask(0022); const LF = "\n"; -define('ROOT', dirname($_SERVER['SCRIPT_FILENAME'])); +define('ROOT', dirname(realpath($_SERVER['SCRIPT_FILENAME']))); if (!extension_loaded('tidy')) echo 'PHP tidy extension unavailable. Feature disabled.' . PHP_EOL;