A lot rewrites from double-quote to single-quote, some fixes for extension handling...
[mailer.git] / inc / modules / admin / what-theme_edit.php
index 1aab5bbd916219c730a7c70f3da8fd842730fcbb..0db3702c6f3d0b57b2cd83c8d672c2004656007c 100644 (file)
 if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("theme")) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "theme");
+} elseif (!EXT_IS_ACTIVE('theme')) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'theme');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Check for selected themes
 $SEL = 0;
 if (REQUEST_ISSET_POST('sel')) $SEL = SELECTION_COUNT(REQUEST_POST('sel'));
 if ($SEL > 0) {
-       $OUT = "";
+       $OUT = '';
        foreach (REQUEST_POST('sel') as $id => $sel) {
-               $sql = "";
+               $sql = '';
                // Shall I de-/activate or delete themes?
                if (REQUEST_ISSET_POST(('status'))) {
                        // Change status
-                       if (REQUEST_POST('active', $id) == "Y") {
+                       if (REQUEST_POST('active', $id) == 'Y') {
                                $sql = "UPDATE `{!_MYSQL_PREFIX!}_themes` SET theme_active='N' WHERE id='".$id."' LIMIT 1";
                        } else {
                                $sql = "UPDATE `{!_MYSQL_PREFIX!}_themes` SET theme_active='Y' WHERE id='".$id."' LIMIT 1";
@@ -98,10 +98,10 @@ if ($SEL > 0) {
 }
 
 // Switch to testing mode
-$GLOBALS['theme_mode'] = "test";
+$GLOBALS['theme_mode'] = 'test';
 
 // Generate output lines for the template
-$OUT = ""; $SW = 2;
+$OUT = ''; $SW = 2;
 $result = SQL_QUERY("SELECT id, theme_path, theme_active, theme_ver, theme_name FROM `{!_MYSQL_PREFIX!}_themes` ORDER BY theme_path", __FILE__, __LINE__);
 if (SQL_NUMROWS($result) > 0) {
        while ($content = SQL_FETCHARRAY($result)) {
@@ -140,7 +140,7 @@ if (SQL_NUMROWS($result) > 0) {
                // No themes found???
        $OUT .= "<tr>
   <td colspan=\"7\" class=\"bottom2\" height=\"60\">
-    ".LOAD_TEMPLATE("admin_settings_saved", true, getMessage('ADMIN_NO_THEMES_FOUND'))."
+    ".LOAD_TEMPLATE('admin_settings_saved', true, getMessage('ADMIN_NO_THEMES_FOUND'))."
   </td>
 </tr>\n";
 }