X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Fmodules%2Fadmin%2Fwhat-list_yoomedia_tm.php;h=52a78cbd4d4a4a60b0ab0b4c217fec818ff90eb9;hb=bdca58e2ac18d5f06a6b8a30a3488eb1360b67d9;hp=925b7b083759edf5ff54f0c439dc2dedf379d9a0;hpb=18e32f1a8971b18bace4f051094acf27800bd7d9;p=mailer.git diff --git a/inc/modules/admin/what-list_yoomedia_tm.php b/inc/modules/admin/what-list_yoomedia_tm.php index 925b7b0837..52a78cbd4d 100644 --- a/inc/modules/admin/what-list_yoomedia_tm.php +++ b/inc/modules/admin/what-list_yoomedia_tm.php @@ -14,12 +14,10 @@ * $Date:: $ * * $Tag:: 0.2.1-FINAL $ * * $Author:: $ * - * Needs to be in all Files and every File needs "svn propset * - * svn:keywords Date Revision" (autoprobset!) at least!!!!!! * * -------------------------------------------------------------------- * * Copyright (c) 2003 - 2009 by Roland Haeder * - * Copyright (c) 2009, 2010 by Mailer Developer Team * - * For more information visit: http://www.mxchange.org * + * Copyright (c) 2009 - 2011 by Mailer Developer Team * + * 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 * @@ -42,28 +40,25 @@ if ((!defined('__SECURITY')) || (!isAdmin())) { } // END - if // Add description as navigation point -addMenuDescription('admin', __FILE__); +addYouAreHereLink('admin', __FILE__); -if (!isExtensionActive('yoomedia')) { - loadTemplate('admin_settings_saved', false, generateExtensionInactiveNotInstalledMessage('yoomedia')); +if (!isExtensionActive('bonus')) { + displayMessage('{%pipe,generateExtensionInactiveNotInstalledMessage=bonus%}'); return; -} elseif (!isExtensionActive('bonus')) { - loadTemplate('admin_settings_saved', false, generateExtensionInactiveNotInstalledMessage('bonus')); - return; -} +} // END - if // Do actions here if (isFormSent()) { // Prepare mail for delivery YOOMEDIA_PREPARE_MAIL_DELIVERY(postRequestArray()); return; -} elseif (isPostRequestParameterSet('sent')) { +} elseif (isPostRequestElementSet('sent')) { // Sent mail YOOMEDIA_SEND_BONUS_MAIL(postRequestArray(), 'normal'); -} elseif (isFormSent('remove')) { +} elseif (isFormSent('do_delete')) { // Add mail to exclude list YOOMEDIA_EXCLUDE_MAIL(postRequestArray(), 'normal'); -} elseif (isPostRequestParameterSet('unlist')) { +} elseif (isPostRequestElementSet('unlist')) { // Remove mail from exclude list YOOMEDIA_UNLIST_MAIL(postRequestArray(), 'normal'); } @@ -71,7 +66,7 @@ if (isFormSent()) { // Enougth queries left? if (getConfig('yoomedia_requests_remain') == '0') { // Output message - loadTemplate('admin_settings_saved', false, getMessage('ADMIN_YOOMEDIA_REQUESTS_DEPLETED')); + displayMessage('{--ADMIN_YOOMEDIA_REQUESTS_DEPLETED--}'); // Abort here! return false; @@ -83,7 +78,7 @@ $result = YOOMEDIA_GET_PARSED_RESULT_TEXTMAILS(); // Sanity-check on result array if ((!is_array($result)) || (count($result) == 0) || (!isset($result[0]['id']))) { // Invalid result - loadTemplate('admin_settings_saved', false, getMessage('ADMIN_YOOMEDIA_INVALID_RESULT')); + displayMessage('{--ADMIN_YOOMEDIA_INVALID_RESULT--}'); return false; } elseif (count($result[0]) < 7) { // Error received so prepare error code @@ -95,12 +90,10 @@ if ((!is_array($result)) || (count($result) == 0) || (!isset($result[0]['id']))) } // Prepare all entries -$OUT = ''; $SW = 2; +$OUT = ''; foreach ($result as $entry) { // Translate some data $entry['pay'] = translateComma($entry['pay'], true, 5); - $entry['remain'] = translateComma($entry['remain']); - $entry['sw'] = $SW; // Check reload lock $reload = YOOMEDIA_CHECK_RELOAD($entry['id'], $entry['reload'], 'textmail'); @@ -122,10 +115,10 @@ foreach ($result as $entry) { } // END - if // Add reload lock - $entry['already'] = getMaskedMessage('ADMIN_YOOMEDIA_TEXTMAIL_SEND_AGAIN', createFancyTime($countdown)); + $entry['already'] = '{%message,ADMIN_YOOMEDIA_TEXTMAIL_SEND_AGAIN=' . $countdown . '%}'; } else { // Never resentable unless manual removal - $entry['already'] = getMessage('ADMIN_YOOMEDIA_TEXTMAIL_MANUALLY_LOCKED'); + $entry['already'] = '{--ADMIN_YOOMEDIA_TEXTMAIL_MANUALLY_LOCKED--}'; } // Load row template for displaying @@ -134,10 +127,7 @@ foreach ($result as $entry) { // Load row template with buttons $OUT .= loadTemplate('admin_list_yoomedia_tm_row', true, $entry); } - - // Switch color - $SW = 3 - $SW; -} // END - if +} // END - foreach // Load main template loadTemplate('admin_list_yoomedia_tm', false, $OUT);