From d742de4e1100df15153784fa0702a334cd388d73 Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Sun, 2 Nov 2008 19:56:57 +0000 Subject: Improve welcome scaffolding to walk you through getting the var directory set up correctly and a database config file in place. --- index.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'index.php') diff --git a/index.php b/index.php index a9310500..9d278e62 100644 --- a/index.php +++ b/index.php @@ -49,7 +49,11 @@ if (PHP_SAPI == 'cli') { @system('mkdir -p test/var/logs'); define('VARPATH', realpath('test/var') . '/'); } else { - define('VARPATH', realpath('var') . '/'); + if (file_exists('var')) { + define('VARPATH', realpath('var') . '/'); + } else { + define('VARPATH', getcwd() . "/var/"); + } } // Initialize. -- cgit v1.2.3