]> git.mxchange.org Git - mailer.git/blobdiff - inc/modules/admin/what-list_task.php
A lot eval() commands rewritten to constant() function
[mailer.git] / inc / modules / admin / what-list_task.php
index 9eb983342fd9caccdd8022ae9ca2e38ff2d09b03..c00272e2870ccad4d9b9eadf41dd1edfca2d26b6 100644 (file)
@@ -41,7 +41,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", basename(__FILE__));
+ADD_DESCR("admin", __FILE__);
 
 $whereStatement = "";
 if (empty($_GET['type'])) $_GET['type'] = "your";
@@ -119,8 +119,7 @@ ORDER BY userid DESC, task_type DESC, subject, task_created DESC", __FILE__, __L
                }
 
                // There are uncompleted jobs!
-               $eval = "\$type = ADMIN_OVERVIEW_TASK_".strtoupper($_GET['type'])."_TYPE;";
-               eval($eval);
+               $type = constant('ADMIN_OVERVIEW_TASK_'.strtoupper($_GET['type']).'_TYPE');
                LOAD_TEMPLATE("admin_overview_header_task", false, array(
                        'message' => $type,
                        'type'    => $_GET['type']
@@ -149,8 +148,10 @@ ORDER BY userid DESC, task_type DESC, subject, task_created DESC", __FILE__, __L
                                        $admin = "<FONT class=\"admin_note\">".ADMIN_ID_404_1.$admin.ADMIN_ID_404_2."</FONT>";
                                }
                        }
-                       $evl = "\$type_out = ADMIN_TASK_IS_".strtoupper($type).";";
-                       eval($evl);
+
+                       // Get admin task
+                       $type_out = constant('ADMIN_TASK_IS_'.strtoupper($type).'');
+
                        $type2 = substr($text, 0, strpos($text, ":"));
                        // Generate infos
                        switch ($type)