# HG changeset patch # User rejo # Date 1209409506 0 # Node ID ad667d767a0af3109123286cd0537bb424570359 # Parent bef105ffb0179fed3ba02acb854cabc64f749be2 [feladat @ 250] Added a check for the existence of the install/ direcory. If it exists, present the user with an error message. diff -r bef105ffb017 -r ad667d767a0a docs/i18n-template-php.pot --- a/docs/i18n-template-php.pot Mon Apr 28 18:47:19 2008 +0000 +++ b/docs/i18n-template-php.pot Mon Apr 28 19:05:06 2008 +0000 @@ -16,6 +16,9 @@ "Content-Type: text/plain; charset=CHARSET\n" "Content-Transfer-Encoding: 8bit\n" +msgid "The install/ directory exists, you must remove it first before proceeding." +msgstr "" + msgid "There is no zone with this ID." msgstr "" diff -r bef105ffb017 -r ad667d767a0a inc/error.inc.php --- a/inc/error.inc.php Mon Apr 28 18:47:19 2008 +0000 +++ b/inc/error.inc.php Mon Apr 28 19:05:06 2008 +0000 @@ -59,6 +59,7 @@ define("ERR_UNKNOWN", _('Unknown error.')); define("ERR_INV_EMAIL", _('Enter a valid email address.')); define("ERR_ZONE_NOT_EXIST", _('There is no zone with this ID.')); +define("ERR_INSTALL_DIR_EXISTS", _('The install/ directory exists, you must remove it first before proceeding.')); /* DATABASE */ define("ERR_DB_NO_DB_NAME", _('No database name has been set in config.inc.php.')); diff -r bef105ffb017 -r ad667d767a0a inc/header.inc.php --- a/inc/header.inc.php Mon Apr 28 18:47:19 2008 +0000 +++ b/inc/header.inc.php Mon Apr 28 19:05:06 2008 +0000 @@ -35,8 +35,11 @@ echo "

Poweradmin

\n"; -if (isset($_SESSION["userid"])) { - +if (file_exists('install')) { + error(ERR_INSTALL_DIR_EXISTS); + include('inc/footer.inc.php'); + exit; +} elseif (isset($_SESSION["userid"])) { verify_permission('search') ? $perm_search = "1" : $perm_search = "0" ; verify_permission('zone_content_view_own') ? $perm_view_zone_own = "1" : $perm_view_zone_own = "0" ; verify_permission('zone_content_view_other') ? $perm_view_zone_other = "1" : $perm_view_zone_other = "0" ; @@ -73,4 +76,3 @@ echo "
\n"; - diff -r bef105ffb017 -r ad667d767a0a locale/nl_NL/LC_MESSAGES/messages.mo Binary file locale/nl_NL/LC_MESSAGES/messages.mo has changed diff -r bef105ffb017 -r ad667d767a0a locale/nl_NL/LC_MESSAGES/nl.po --- a/locale/nl_NL/LC_MESSAGES/nl.po Mon Apr 28 18:47:19 2008 +0000 +++ b/locale/nl_NL/LC_MESSAGES/nl.po Mon Apr 28 19:05:06 2008 +0000 @@ -16,6 +16,10 @@ "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" + +msgid "The install/ directory exists, you must remove it first before proceeding." +msgstr "De install/ directory bestaat (nog), deze moet verwijderd worden voordat Poweradmin gebruikt kan worden." + msgid "There is no zone with this ID." msgstr "Er bestaat geen zone met dit ID."