]> git.mxchange.org Git - mailer.git/blobdiff - inc/modules/admin/admin-inc.php
Bad things are now 'classified' as bad (CSS class 'bad' is being used instead of...
[mailer.git] / inc / modules / admin / admin-inc.php
index 395535e502949165ee9c6e136a9419b3e37d5a21..fb70b05816708e712cf0e756b55367677d6e2d7f 100644 (file)
@@ -296,7 +296,7 @@ ORDER BY
                                                $OUT .= '[<a href="{%url=modules.php?module=admin&amp;action=' . $menu . '%}">';
                                        }
                                } else {
-                                       $OUT .= '<em style="cursor:help" class="notice" title="{%message,ADMIN_MENU_ACTION_404_TITLE=' . $menu . '%}">';
+                                       $OUT .= '<em style="cursor:help" class="bad" title="{%message,ADMIN_MENU_ACTION_404_TITLE=' . $menu . '%}">';
                                }
 
                                $OUT .= $title;
@@ -359,7 +359,7 @@ ORDER BY
                                                                        $OUT .= '[<a href="{%url=modules.php?module=admin&amp;what=' . $what_sub . '%}">';
                                                                }
                                                        } else {
-                                                               $OUT .= '<em style="cursor:help" class="notice" title="{%message,ADMIN_MENU_WHAT_404_TITLE=' . $what_sub . '%}">';
+                                                               $OUT .= '<em style="cursor:help" class="bad" title="{%message,ADMIN_MENU_WHAT_404_TITLE=' . $what_sub . '%}">';
                                                        }
 
                                                        $OUT .= $title_what;
@@ -1298,7 +1298,7 @@ function adminAddEntries ($tableName, $columns = array(), $filterFunctions = arr
        $sqlValues  = array();
 
        // Add columns and values
-       foreach ($columns as $key=>$columnName) {
+       foreach ($columns as $key => $columnName) {
                // Copy entry to final arrays
                $sqlColumns[$key] = $columnName;
                $sqlValues[$key]  = postRequestElement($columnName);
@@ -1312,7 +1312,7 @@ function adminAddEntries ($tableName, $columns = array(), $filterFunctions = arr
        } // END - foreach
 
        // Build the SQL query
-       $SQL = 'INSERT INTO `{?_MYSQL_PREFIX?}_' . $tableName[0] . '` (`' . implode('`, `', $sqlColumns) . "`) VALUES ('" . implode("','", $sqlValues) . "')";
+       $SQL = 'INSERT INTO `{?_MYSQL_PREFIX?}_' . $tableName[0] . '` (`' . implode('`,`', $sqlColumns) . "`) VALUES ('" . implode("','", $sqlValues) . "')";
 
        // Run the SQL query
        SQL_QUERY($SQL, __FUNCTION__, __LINE__);
@@ -1372,7 +1372,7 @@ function adminListEntries ($tableTemplate, $rowTemplate, $noEntryMessageId, $tab
        if (count($orderByColumns) > 0) {
                // Add them as well
                $SQL .= ' ORDER BY ';
-               foreach ($orderByColumns as $orderByColumn=>$array) {
+               foreach ($orderByColumns as $orderByColumn => $array) {
                        // Get keys (table/alias) and values (sorting itself)
                        $table   = trim(implode('', array_keys($array)));
                        $sorting = trim(implode('', array_keys($array)));
@@ -1406,7 +1406,7 @@ function doAdminListEntries ($SQL, $tableTemplate, $noEntryMessageId, $rowTempla
                $OUT = '';
                while ($content = SQL_FETCHARRAY($result)) {
                        // "Translate" content
-                       foreach ($callbackColumns as $columnName=>$callbackFunction) {
+                       foreach ($callbackColumns as $columnName => $callbackFunction) {
                                // Fill the callback arguments
                                $args = array($content[$columnName]);
 
@@ -1474,7 +1474,7 @@ function sendAdminPasswordResetLink ($email) {
        SQL_FREERESULT($result);
 
        // Generate hash for reset link
-       $content['hash'] = generateHash(getUrl() . getEncryptSeperator() . $content['id'] . getEncryptSeperator() . $content['login'] . getEncryptSeperator() . $content['password'], substr($content['password'], getSaltLength()));
+       $content['hash'] = generateHash(getUrl() . getEncryptSeparator() . $content['id'] . getEncryptSeparator() . $content['login'] . getEncryptSeparator() . $content['password'], substr($content['password'], getSaltLength()));
 
        // Remove some data
        unset($content['id']);
@@ -1505,7 +1505,7 @@ function adminResetValidateHashLogin ($hash, $login) {
                $content = SQL_FETCHARRAY($result);
 
                // Generate hash again
-               $hashFromData = generateHash(getUrl() . getEncryptSeperator() . $content['id'] . getEncryptSeperator() . $login . getEncryptSeperator() . $content['password'], substr($content['password'], getSaltLength()));
+               $hashFromData = generateHash(getUrl() . getEncryptSeparator() . $content['id'] . getEncryptSeparator() . $login . getEncryptSeparator() . $content['password'], substr($content['password'], getSaltLength()));
 
                // Does both match?
                $valid = ($hash == $hashFromData);
@@ -1630,7 +1630,7 @@ function generateAdminLink ($adminId) {
                        }
                } else {
                        // Maybe deleted?
-                       $adminLink = '<div class="notice">{%message,ADMIN_ID_404=' . $adminId . '%}</div>';
+                       $adminLink = '<div class="bad">{%message,ADMIN_ID_404=' . $adminId . '%}</div>';
                }
        } // END - if
 
@@ -1759,7 +1759,7 @@ function addEmailNavigation ($numPages, $offset, $show_form, $colspan, $return=f
                        $NAV .= '</a>';
                }
 
-               // Add seperator if we have not yet reached total pages
+               // Add separator if we have not yet reached total pages
                if ($page < $numPages) {
                        // Add it
                        $NAV .= '|';
@@ -1799,7 +1799,7 @@ function adminProcessMenuEditForm ($type, $subMenu) {
                        case 'edit': // Edit menu
                                if (postRequestElement('sel_what', $sel) == '') {
                                        // Update with 'what'=null
-                                       SQL_QUERY_ESC("UPDATE `{?_MYSQL_PREFIX?}_%s_menu` SET `title`='%s', `action`='%s', `what`=NULL WHERE ".$AND." AND `id`=%s LIMIT 1",
+                                       SQL_QUERY_ESC("UPDATE `{?_MYSQL_PREFIX?}_%s_menu` SET `title`='%s',`action`='%s',`what`=NULL WHERE ".$AND." AND `id`=%s LIMIT 1",
                                                array(
                                                        $type,
                                                        $menu,
@@ -1808,7 +1808,7 @@ function adminProcessMenuEditForm ($type, $subMenu) {
                                                ), __FILE__, __LINE__);
                                } else {
                                        // Update with selected 'what'
-                                       SQL_QUERY_ESC("UPDATE `{?_MYSQL_PREFIX?}_%s_menu` SET `title`='%s', `action`='%s', `what`='%s' WHERE ".$AND." AND `id`=%s LIMIT 1",
+                                       SQL_QUERY_ESC("UPDATE `{?_MYSQL_PREFIX?}_%s_menu` SET `title`='%s',`action`='%s',`what`='%s' WHERE ".$AND." AND `id`=%s LIMIT 1",
                                                array(
                                                        $type,
                                                        $menu,
@@ -1825,7 +1825,7 @@ function adminProcessMenuEditForm ($type, $subMenu) {
                                break;
 
                        case 'status': // Change status of menus
-                               SQL_QUERY_ESC("UPDATE `{?_MYSQL_PREFIX?}_%s_menu` SET `visible`='%s', `locked`='%s' WHERE ".$AND." AND `id`=%s LIMIT 1",
+                               SQL_QUERY_ESC("UPDATE `{?_MYSQL_PREFIX?}_%s_menu` SET `visible`='%s',`locked`='%s' WHERE ".$AND." AND `id`=%s LIMIT 1",
                                        array($type, postRequestElement('visible', $sel), postRequestElement('locked', $sel), $sel), __FILE__, __LINE__);
                                break;