]> git.mxchange.org Git - mailer.git/blobdiff - inc/modules/admin/what-list_beg.php
More EL used, this has fixed double calls of translateComma() in various places
[mailer.git] / inc / modules / admin / what-list_beg.php
index 954a70a92f87f36a06e2e72aa65499212c9066fa..65711bcf700fb3a86621091b29dd34e676ed15f1 100644 (file)
@@ -14,8 +14,6 @@
  * $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                    *
 // Some security stuff...
 if ((!defined('__SECURITY')) || (!isAdmin())) {
        die();
-}
+} // END - if
 
 // Add description as navigation point
 addMenuDescription('admin', __FILE__);
 
-if (getConfig('beg_rallye') == 'Y') {
+if (isBegRallyeEnabled()) {
        // Shall I withdraw now?
        if (isPostRequestParameterSet('withdraw')) {
                // Okay, let's prepare...
@@ -67,13 +65,15 @@ if (getConfig('beg_rallye') == 'Y') {
 FROM
        `{?_MYSQL_PREFIX?}_user_data`
 WHERE
-       `status`='CONFIRMED' AND beg_points > 0".$lastOnline."
+       `status`='CONFIRMED' AND
+       `beg_points` > 0
+       " . $lastOnline . "
 ORDER BY
        `beg_points` DESC,
        `last_online` DESC,
        `userid` ASC", __FILE__, __LINE__);
 
-       if (SQL_NUMROWS($result) > 0) {
+       if (!SQL_HASZERONUMS($result)) {
                // List users
                $OUT = ''; $cnt = 1; $total = '0';
                while ($content = SQL_FETCHARRAY($result)) {
@@ -105,7 +105,7 @@ ORDER BY
                } // END - while
 
                $content['rows']  = $OUT;
-               $content['total'] = translateComma($total);
+               $content['total'] = $total;
 
                // Check if we need to display form or not with manuel withdraw
                if (getConfig('last_month') == getMonth()) {
@@ -113,14 +113,14 @@ ORDER BY
                        $content['withdraw_form'] = loadTemplate('admin_list_beg_form', true);
                } else {
                        // Display message "no manual withdraw possible"
-                       $content['withdraw_form'] = loadTemplate('admin_settings_saved', true, '<div class="admin_failed">{--ADMIN_BEG_ALREADY_WITHDRAW--}</div>');
+                       $content['withdraw_form'] = loadTemplate('admin_settings_saved', true, '{--ADMIN_BEG_ALREADY_WITHDRAW--}');
                }
 
                // Prepare constant for timemark
                if (isExtensionActive('autopurge')) {
                        $content['autopurge_timeout'] = generateDateTime(time() - getApInactiveSince(), 2);
                } else {
-                       $content['autopurge_timeout'] = loadTemplate('admin_settings_saved', true, getMaskedMessage('EXTENSION_PROBLEM_EXTENSION_NOT_INSTALLED', 'autopurge'));
+                       $content['autopurge_timeout'] = loadTemplate('admin_settings_saved', true, generateExtensionInactiveNotInstalledMessage('autopurge'));
                }
 
                // Load final template