From 6c7f37aacc883b7f2d7e9cea3df0f6eb0f127871 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Sun, 31 Aug 2008 16:14:05 +0000 Subject: [PATCH] Parse error in optimize extension fixed --- inc/language/optimize_de.php | 1 + inc/modules/admin/what-optimize.php | 4 +++- inc/modules/admin/what-send_newsletter.php | 4 ++-- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/inc/language/optimize_de.php b/inc/language/optimize_de.php index 86946fafed..4f2f778eb7 100644 --- a/inc/language/optimize_de.php +++ b/inc/language/optimize_de.php @@ -45,6 +45,7 @@ define('OPTIMIZE_OPTIMIZED', "Optimiert"); define('OPTIMIZE_TOTAL_SIZE', "Gesamtgrösse"); define('OPTIMIZE_GAIN_SIZE', "Eingespart"); define('OPTIMIZE_STATUS_OK', "Nein"); +define('OPTIMIZE_STATUS_UNSUPPORTED', "Nicht möglich"); define('OPTIMIZE_STATUS_OPTIMIZED', "Optimiert!"); define('OPTIMIZE_DB_TOTAL_TABLES', "Gesamtzahl angelegter Tabellen"); define('OPTIMIZE_DB_TOTAL_SIZE', "Gesamtgröße der Datenbank"); diff --git a/inc/modules/admin/what-optimize.php b/inc/modules/admin/what-optimize.php index be5a6e3b4d..2c88f2a89a 100644 --- a/inc/modules/admin/what-optimize.php +++ b/inc/modules/admin/what-optimize.php @@ -51,15 +51,17 @@ foreach ($DATA['tables'] as $row_array) if (empty($row_array[1])) $row_array[1] = "NONE"; $eval = "\$REP = OPTIMIZE_STATUS_".strtoupper($row_array[1]).";"; eval($eval); $B1 = ""; $B2 = ""; + $OPT = OPTIMIZE_STATUS_UNSUPPORTED; if ($row_array[4] > 0) { $OPT = OPTIMIZE_STATUS_OPTIMIZED; $B1 = ""; $B2 = ""; $gain_tabs++; } - else + elseif (count(explode(" ", $row_array[2])) == 0) { $eval = "\$OPT = OPTIMIZE_STATUS_".strtoupper($row_array[2]).";"; + die($eval); eval($eval); } diff --git a/inc/modules/admin/what-send_newsletter.php b/inc/modules/admin/what-send_newsletter.php index 9a4377833f..6354125f5f 100644 --- a/inc/modules/admin/what-send_newsletter.php +++ b/inc/modules/admin/what-send_newsletter.php @@ -32,11 +32,11 @@ ************************************************************************/ // Some security stuff... -if ((ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) || (!IS_ADMIN())) -{ +if ((ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) || (!IS_ADMIN())) { $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php"; require($INC); } + // Add description as navigation point ADD_DESCR("admin", basename(__FILE__)); -- 2.39.5