X-Git-Url: https://git.mxchange.org/?p=mailer.git;a=blobdiff_plain;f=inc%2Fmodules%2Fadmin%2Fwhat-stats_mods.php;h=93cc0b4f08167b838e0dc8080c0a6603ac280cec;hp=59a1c99fa3d6c45f4edab75a510998519b6a793d;hb=0f3a135204757cc8750262871c8e62c42300acb4;hpb=5bdeaf8b452206598b6c6cd4f941145b11a0eccc
diff --git a/inc/modules/admin/what-stats_mods.php b/inc/modules/admin/what-stats_mods.php
index 59a1c99fa3..93cc0b4f08 100644
--- a/inc/modules/admin/what-stats_mods.php
+++ b/inc/modules/admin/what-stats_mods.php
@@ -1,7 +1,7 @@
$SW,
- 'title' => $title,
- 'action' => $act,
- 'clicks' => $clicks,
- );
-
+ $OUT = '';
+ while ($content = SQL_FETCHARRAY($result)) {
// Load row template
- $OUT .= LOAD_TEMPLATE("admin_mods_stats2_row", true, $content);
-
- // Switch colors
- $SW = 3 - $SW;
- }
+ $OUT .= loadTemplate('admin_list_mods_stats2_row', true, $content);
+ } // END - while
// Free memory
SQL_FREERESULT($result);
- define('__MODS_ROWS', $OUT);
// Load final template
- LOAD_TEMPLATE("admin_mods_stats2");
+ loadTemplate('admin_list_mods_stats2', false, $OUT);
} else {
// Load module statics
- $result = SQL_QUERY("SELECT module, title, clicks FROM `{!_MYSQL_PREFIX!}_mod_reg` ORDER BY clicks DESC, module", __FILE__, __LINE__);
- $SW = 2; $OUT = "";
- while (list($mod, $title, $clicks) = SQL_FETCHROW($result)) {
- if (empty($title)) $title = "---";
- if (($mod == "index") || ($mod == "login"))
- {
+ $result = SQL_QUERY("SELECT `module`,`title`,`clicks` FROM `{?_MYSQL_PREFIX?}_mod_reg` ORDER BY `clicks` DESC, `module` ASC", __FILE__, __LINE__);
+ $OUT = '';
+ while ($content = SQL_FETCHARRAY($result)) {
+ if (($content['module'] == 'index') || ($content['module'] == 'login')) {
// Add link to detail statistics
- $mod = "".$mod."";
- }
- // Prepare array for the template
- $content = array(
- 'sw' => $SW,
- 'title' => $title,
- 'mod' => $mod,
- 'clicks' => $clicks,
- );
+ $content['module'] = '' . $content['module'] . '';
+ } // END - if
// Load row template
- $OUT .= LOAD_TEMPLATE("admin_mods_stats_row", true, $content);
- }
+ $OUT .= loadTemplate('admin_list_mods_stats_row', true, $content);
+ } // END - while
// Free memory
SQL_FREERESULT($result);
- define('__MODS_ROWS', $OUT);
// Load final template
- LOAD_TEMPLATE("admin_mods_stats");
+ loadTemplate('admin_list_mods_stats', false, $OUT);
}
-//
+
+// [EOF]
?>