From 7f17a38d358bdec609a98827991108032e9257ee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nicolas=20L=C5=93uillet?= Date: Thu, 3 Oct 2013 14:23:03 +0200 Subject: change instructions messages --- inc/poche/Poche.class.php | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/inc/poche/Poche.class.php b/inc/poche/Poche.class.php index 1bae2751..d6dbd19a 100644 --- a/inc/poche/Poche.class.php +++ b/inc/poche/Poche.class.php @@ -109,6 +109,14 @@ class Poche return false; } + + if (! is_writable(CACHE)) { + $this->notInstalledMessage = '

error

You don\'t have write access on cache directory.

'; + + self::$canRenderTemplates = false; + + return false; + } # Check if the selected theme and its requirements are present if (! is_dir(THEME . '/' . $this->getTheme())) { @@ -145,16 +153,11 @@ class Poche if (empty($configSalt)) { $msg = '

error

You have not yet filled in the SALT value in the config.inc.php file.

'; - } else if (! is_writable(CACHE)) { - Tools::logm('you don\'t have write access on cache directory'); - $msg = '

error

You don\'t have write access on cache directory.

'; } else if (STORAGE == 'sqlite' && ! file_exists(STORAGE_SQLITE)) { Tools::logm('sqlite file doesn\'t exist'); $msg = '

error

sqlite file doesn\'t exist, you can find it in install folder. Copy it in /db folder.

'; - } else if (file_exists(ROOT . '/install/update.php') && ! DEBUG_POCHE) { - $msg = '

setup

It\'s your first time here? Please copy /install/poche.sqlite in db folder. Then, delete install folder.
If you have already installed poche, an update is needed by clicking here.

'; } else if (is_dir(ROOT . '/install') && ! DEBUG_POCHE) { - $msg = '

setup

If you want to update your poche, you just have to delete /install folder.
To install your poche with sqlite, copy /install/poche.sqlite in /db and delete the folder /install. you have to delete the /install folder before using poche.

'; + $msg = '

install folder

you have to delete the /install folder before using poche.

'; } else if (STORAGE == 'sqlite' && ! is_writable(STORAGE_SQLITE)) { Tools::logm('you don\'t have write access on sqlite file'); $msg = '

error

You don\'t have write access on sqlite file.

'; -- cgit v1.2.3