X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Fmysql-manager.php;h=8f9d7bb7a9d8113e9597e7862f29f18126223f74;hb=7638ed2cdac53be2f20153011b8093aaf7349f79;hp=51fb3de99dcbfb4adc2dd805352f6d3091c57088;hpb=0f3a135204757cc8750262871c8e62c42300acb4;p=mailer.git diff --git a/inc/mysql-manager.php b/inc/mysql-manager.php index 51fb3de99d..8f9d7bb7a9 100644 --- a/inc/mysql-manager.php +++ b/inc/mysql-manager.php @@ -17,7 +17,7 @@ * -------------------------------------------------------------------- * * Copyright (c) 2003 - 2009 by Roland Haeder * * Copyright (c) 2009 - 2011 by Mailer Developer Team * - * For more information visit: http://www.mxchange.org * + * For more information visit: http://mxchange.org * * * * This program is free software; you can redistribute it and/or modify * * it under the terms of the GNU General Public License as published by * @@ -46,7 +46,7 @@ function getTitleFromMenu ($mode, $what, $column = 'what', $ADD='') { // Fix empty 'what' if (empty($what)) { $what = getIndexHome(); - } elseif ((isGetRequestParameterSet('action')) && ($column == 'what')) { + } elseif ((isGetRequestElementSet('action')) && ($column == 'what')) { // Get it from action return getTitleFromMenu($mode, getAction(), 'action', $ADD); } elseif ($what == 'overview') { @@ -340,16 +340,16 @@ ORDER BY //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'main_cnt=' . $main_cnt . ',getWhat()=' . getWhat()); if (SQL_NUMROWS($result_main) > $main_cnt) { - // Add seperator - $GLOBALS['rows'] .= loadTemplate('menu_seperator', true, $mode); + // Add separator + $GLOBALS['rows'] .= loadTemplate('menu_separator', true, $mode); // Should we display adverts in this menu? if ((isExtensionInstalledAndNewer('menu', '0.0.1')) && (getConfig($mode . '_menu_advert_enabled') == 'Y') && ($action != 'admin')) { // Display advert template $GLOBALS['rows'] .= loadTemplate('menu_' . $mode . '_advert_' . $action, true); - // Add seperator again - $GLOBALS['rows'] .= loadTemplate('menu_seperator', true, $mode); + // Add separator again + $GLOBALS['rows'] .= loadTemplate('menu_separator', true, $mode); } // END - if } // END - if } // END - while @@ -359,8 +359,8 @@ ORDER BY // Should we display adverts in this menu? if ((isExtensionInstalledAndNewer('menu', '0.0.1')) && (getConfig($mode . '_menu_advert_enabled') == 'Y')) { - // Add seperator again - $GLOBALS['rows'] .= loadTemplate('menu_seperator', true, $mode); + // Add separator again + $GLOBALS['rows'] .= loadTemplate('menu_separator', true, $mode); // Display advert template $GLOBALS['rows'] .= loadTemplate('menu_' . $mode . '_advert_end', true); @@ -451,7 +451,10 @@ function fetchUserData ($value, $column = 'userid') { if (!isExtensionActive('user')) { // Absent ext-user is really not good return false; - } // END - if + } elseif (is_null($value)) { + // This shall never happen, so please report it + debug_report_bug(__FUNCTION__, __LINE__, 'value=NULL,column=' . $column . ' - value can never be NULL'); + } // If we should look for userid secure&set it here if (substr($column, -2, 2) == 'id') { @@ -630,7 +633,7 @@ function addMaxReceiveList ($mode, $default = '', $return = false) { $OUT = ''; while ($content = SQL_FETCHARRAY($result)) { $OUT .= ' '; } // END - while } else { // No data found @@ -1372,9 +1422,9 @@ LIMIT 1", // Gets the matching what name from module function getWhatFromModule ($modCheck) { // Is the request element set? - if (isGetRequestParameterSet('what')) { + if (isGetRequestElementSet('what')) { // Then return this! - return getRequestParameter('what'); + return getRequestElement('what'); } // END - if // Default is empty @@ -1641,12 +1691,12 @@ function reduceRecipientReceivedMails ($column, $id, $count) { } // Creates a new task -function createNewTask ($subject, $notes, $taskType, $userid = NULL, $adminId = '0', $strip = true) { +function createNewTask ($subject, $notes, $taskType, $userid = NULL, $adminId = NULL, $strip = true) { // Insert the task data into the database SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_task_system` (`assigned_admin`,`userid`,`status`,`task_type`,`subject`,`text`,`task_created`) VALUES (%s,%s,'NEW','%s','%s','%s', UNIX_TIMESTAMP())", array( - $adminId, - $userid, + makeZeroToNull($adminId), + makeZeroToNull($userid), $taskType, $subject, $notes