Fix for rewritting code #3
authorRoland Häder <roland@mxchange.org>
Wed, 18 Nov 2009 04:24:23 +0000 (04:24 +0000)
committerRoland Häder <roland@mxchange.org>
Wed, 18 Nov 2009 04:24:23 +0000 (04:24 +0000)
inc/modules/admin/what-admins_mails.php

index 21ad2e4bdb11bfe6324953b55dcc4cd2be902cfe..d07a7d120eec2591ea76413cc94403830b6b465b 100644 (file)
@@ -52,7 +52,7 @@ if (isPostRequestElementSet('edit')) {
                $SW = 2; $rowNameS = '';
                foreach (postRequestElement('sel') as $template => $sel) {
                        // First of all load data from DB
                $SW = 2; $rowNameS = '';
                foreach (postRequestElement('sel') as $template => $sel) {
                        // First of all load data from DB
-                       $result = SQL_QUERY_ESC("SELECT `admin_id`, `id`, `mail_template` FROM `{?_MYSQL_PREFIX?}_admins_mails` WHERE `mail_template`='%s' ORDER BY `id` ASC",
+                       $result = SQL_QUERY_ESC("SELECT `admin_id`, `id` FROM `{?_MYSQL_PREFIX?}_admins_mails` WHERE `mail_template`='%s' ORDER BY `id` ASC",
                                array($template), __FILE__, __LINE__);
                        $OUT = '';
                        $adminId2 = '0';
                                array($template), __FILE__, __LINE__);
                        $OUT = '';
                        $adminId2 = '0';
@@ -79,8 +79,9 @@ if (isPostRequestElementSet('edit')) {
                        SQL_FREERESULT($result);
 
                        // Prepare content
                        SQL_FREERESULT($result);
 
                        // Prepare content
-                       $content['sw']     = $SW;
-                       $content['admins'] = $adminsList;
+                       $content['sw']            = $SW;
+                       $content['mail_template'] = $template;
+                       $content['admins']        = $adminsList;
 
                        if ($adminId2 > 0) {
                                // Add form for an additional admin
 
                        if ($adminId2 > 0) {
                                // Add form for an additional admin