From 8c2c5d287d5ac08aa9d0a3fb3d353ea7a18c92c3 Mon Sep 17 00:00:00 2001 From: Marien Fressinaud Date: Sun, 14 Apr 2013 18:57:47 +0200 Subject: Fix issue #43 : création d'un installateur MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/index.php | 26 +++++++++++++++----------- 1 file changed, 15 insertions(+), 11 deletions(-) (limited to 'public/index.php') diff --git a/public/index.php b/public/index.php index 330843719..4e39d028e 100755 --- a/public/index.php +++ b/public/index.php @@ -25,16 +25,20 @@ define ('APP_PATH', realpath (PUBLIC_PATH . '/../app')); define ('LOG_PATH', realpath (PUBLIC_PATH . '/../log')); define ('CACHE_PATH', realpath (PUBLIC_PATH . '/../cache')); -set_include_path (get_include_path () - . PATH_SEPARATOR - . LIB_PATH - . PATH_SEPARATOR - . LIB_PATH . '/minz' - . PATH_SEPARATOR - . APP_PATH); +if (file_exists (PUBLIC_PATH . '/install.php')) { + include ('install.php'); +} else { + set_include_path (get_include_path () + . PATH_SEPARATOR + . LIB_PATH + . PATH_SEPARATOR + . LIB_PATH . '/minz' + . PATH_SEPARATOR + . APP_PATH); -require (APP_PATH . '/App_FrontController.php'); + require (APP_PATH . '/App_FrontController.php'); -$front_controller = new App_FrontController (); -$front_controller->init (); -$front_controller->run (); + $front_controller = new App_FrontController (); + $front_controller->init (); + $front_controller->run (); +} -- cgit v1.2.3