Several more constants rewritten to getConfig()
[mailer.git] / inc / libs / admins_functions.php
index 40b6da9e686be921842c5d5a2fc839d9beaf08b9..d42f59fe26f253f5e888f92826f77e497d8c10c7 100644 (file)
@@ -138,14 +138,14 @@ LIMIT 1",
                        list($aid) = SQL_FETCHROW($result);
 
                        // Rewrite email address to contact link
-                       $email = "{!URL!}/modules.php?module=".$mod."&what=admins_contct&admin=".bigintval($aid);
+                       $email = "{?URL?}/modules.php?module=".$mod."&what=admins_contct&admin=".bigintval($aid);
                } // END - if
 
                // Free memory
                SQL_FREERESULT($result);
        } elseif ((is_int($email)) && ($email > 0)) {
                // Direct ID given
-               $email = "{!URL!}/modules.php?module=".$mod."&what=admins_contct&admin=".bigintval($email);
+               $email = "{?URL?}/modules.php?module=".$mod."&what=admins_contct&admin=".bigintval($email);
        }
 
        // Return rewritten (?) email address
@@ -272,7 +272,7 @@ function adminsEditAdminAccount ($POST) {
                        // Shall we allow changing default ACL?
                        if ($currMode == 'allow') {
                                // Allow chaning it
-                               $content['mode']    = generateOptionList('/ARRAY/', array('allow', 'deny'), array(constant('ADMINS_ALLOW_MODE'), constant('ADMINS_DENY_MODE')), $content['mode']);
+                               $content['mode']    = generateOptionList('/ARRAY/', array('allow', 'deny'), array(getMessage('ADMINS_ALLOW_MODE'), getMessage('ADMINS_DENY_MODE')), $content['mode']);
                        } else {
                                // Don't allow it
                                $content['mode'] = ' ';
@@ -310,8 +310,8 @@ function adminsDeleteAdminAccount ($POST) {
                                // Entry found
                                $content = SQL_FETCHARRAY($result);
                                SQL_FREERESULT($result);
-                               $content['mode'] = constant('ADMINS_'.strtoupper($content['mode']).'_MODE');
-                               $content['la_mode'] = constant('ADMINS_'.strtoupper($content['la_mode']).'_LA_SETTING');
+                               $content['mode'] = getMessage('ADMINS_'.strtoupper($content['mode']).'_MODE');
+                               $content['la_mode'] = getMessage('ADMINS_'.strtoupper($content['la_mode']).'_LA_SETTING');
 
                                // Prepare some more data
                                $content['sw'] = $SW;
@@ -344,11 +344,11 @@ function adminsRemoveAdminAccount ($POST) {
                if (($del == 1) && (getCurrentAdminId() != $id)) {
                        // Rewrite his tasks to all admins
                        SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_task_system` SET `assigned_admin`=0 WHERE `assigned_admin`=%s",
-                       array($id), __FUNCTION__, __LINE__);
+                               array($id), __FUNCTION__, __LINE__);
 
                        // Remove account
                        SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admins` WHERE `id`=%s LIMIT 1",
-                       array($id), __FUNCTION__, __LINE__);
+                               array($id), __FUNCTION__, __LINE__);
 
                        // Purge cache
                        cachePurgeAdminMenu($id);
@@ -367,8 +367,8 @@ function adminsListAdminAccounts() {
        $OUT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result)) {
                // Compile some variables
-               $content['mode'] = constant('ADMINS_'.strtoupper($content['mode']).'_MODE');
-               $content['la_mode'] = constant('ADMINS_'.strtoupper($content['la_mode']).'_LA_SETTING');
+               $content['mode'] = getMessage('ADMINS_'.strtoupper($content['mode']).'_MODE');
+               $content['la_mode'] = getMessage('ADMINS_'.strtoupper($content['la_mode']).'_LA_SETTING');
 
                // Prepare some more data
                $content['sw']         = $SW;