X-Git-Url: https://git.mxchange.org/?p=mailer.git;a=blobdiff_plain;f=inc%2Fmodules%2Fadmin%2Fwhat-list_user_amounts.php;h=84bf3a6673ed83bd8371a17143350bbc8e0791b9;hp=88f25ca9ab79bfa032a1419c54f27a723ff532dd;hb=49acdb7a7adbcf25a8e8683b5581bfcec72b23bd;hpb=155492a5b96cec674846973a8524238b0365a848 diff --git a/inc/modules/admin/what-list_user_amounts.php b/inc/modules/admin/what-list_user_amounts.php index 88f25ca9ab..84bf3a6673 100644 --- a/inc/modules/admin/what-list_user_amounts.php +++ b/inc/modules/admin/what-list_user_amounts.php @@ -16,7 +16,7 @@ * $Author:: $ * * -------------------------------------------------------------------- * * Copyright (c) 2003 - 2009 by Roland Haeder * - * Copyright (c) 2009 - 2013 by Mailer Developer Team * + * Copyright (c) 2009 - 2015 by Mailer Developer Team * * For more information visit: http://mxchange.org * * * * This program is free software; you can redistribute it and/or modify * @@ -72,7 +72,7 @@ ORDER BY `p`.`userid` ASC', __FILE__, __LINE__); // Are there entries? (sorry, the XML functions cannot "produce" the above SQL statement) -if (!ifSqlHasZeroNums($result)) { +if (!ifSqlHasZeroNumRows($result)) { // Init amounts and points $totalPoints = '0'; $amounts = array(); @@ -93,7 +93,7 @@ if (!ifSqlHasZeroNums($result)) { // ... and display all foreach ($amounts as $userid => $row) { // Calculate and add percentage to data array - $row['percents'] = $row['points'] / $totalPoints * 100; + $row['percents'] = calculatePercentageRate($row['points'], $totalPoints); // Load row template $out['rows'] .= loadTemplate('admin_list_user_amounts_row', TRUE, $row);