From 7dc3f37a81184058663604c7cf27ea8acb510d05 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Wed, 30 Mar 2016 11:00:32 +0200 Subject: [PATCH] Added base_path settings (which you normally don't need to touch) --- index.php | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/index.php b/index.php index 78e5ff4..61c6488 100644 --- a/index.php +++ b/index.php @@ -20,7 +20,10 @@ // Website title 'title' => 'strace.club', - // Directory to store uploaded files + // Base path (auto-detection) + 'base_path' => dirname(__FILE__) . DIRECTORY_SEPARATOR, + + // Directory to store uploaded files (relative to base_path) 'uploaddir' => '.', // Display list uploaded files @@ -100,7 +103,7 @@ $data['ignores'][] = basename($data['scriptname']); // Use canonized path - $data['uploaddir'] = realpath(dirname(__FILE__) . DIRECTORY_SEPARATOR . $settings['uploaddir']); + $data['uploaddir'] = realpath($settings['base_path'] . $settings['uploaddir']); // Maximum upload size, set by system $data['max_upload_size'] = ini_get('upload_max_filesize'); -- 2.39.5