Browse Source

Add IRC line stats to profile pages

spaghetti 8 years ago
parent
commit
ac9506734f
2 changed files with 5 additions and 2 deletions
  1. 1
    0
      sections/user/community_stats.php
  2. 4
    2
      sections/user/user.php

+ 1
- 0
sections/user/community_stats.php View File

@@ -36,6 +36,7 @@ list($UniqueGroups) = $DB->next_record();
36 36
       <div class="head colhead_dark">Community</div>
37 37
       <ul class="stats nobullet">
38 38
         <li id="comm_posts">Forum posts: <?=number_format($ForumPosts)?> <a href="userhistory.php?action=posts&amp;userid=<?=$UserID?>" class="brackets">View</a></li>
39
+        <li id="comm_irc">IRC lines: <?=number_format($IRCLines)?></li>
39 40
 <?  if ($Override = check_paranoia_here('torrentcomments+')) { ?>
40 41
         <li id="comm_torrcomm"<?=($Override === 2 ? ' class="paranoia_override"' : '')?>>Torrent comments: <?=number_format($NumComments)?>
41 42
 <?        if ($Override = check_paranoia_here('torrentcomments')) { ?>

+ 4
- 2
sections/user/user.php View File

@@ -40,6 +40,7 @@ if (check_perms('users_mod')) { // Person viewing is a staff member
40 40
       m.can_leech,
41 41
       m.Visible,
42 42
       m.BonusPoints,
43
+      m.IRCLines,
43 44
       i.JoinDate,
44 45
       i.Info,
45 46
       i.Avatar,
@@ -84,7 +85,7 @@ if (check_perms('users_mod')) { // Person viewing is a staff member
84 85
     header("Location: log.php?search=User+$UserID");
85 86
   }
86 87
 
87
-  list($Username, $Email, $LastAccess, $IP, $Class, $Uploaded, $Downloaded, $RequiredRatio, $CustomTitle, $torrent_pass, $Enabled, $Paranoia, $Invites, $DisableLeech, $Visible, $BonusPoints, $JoinDate, $Info, $Avatar, $AdminComment, $Donor, $Artist, $Warned, $SupportFor, $RestrictedForums, $PermittedForums, $InviterID, $InviterName, $ForumPosts, $RatioWatchEnds, $RatioWatchDownload, $DisableAvatar, $DisableInvites, $DisablePosting, $DisableForums, $DisableTagging, $DisableUpload, $DisableWiki, $DisablePM, $DisablePoints, $DisablePromotion, $DisableIRC, $DisableRequests, $FLTokens, $CommentHash, $InfoTitle, $LockedAccount) = $DB->next_record(MYSQLI_NUM, array(8, 11));
88
+  list($Username, $Email, $LastAccess, $IP, $Class, $Uploaded, $Downloaded, $RequiredRatio, $CustomTitle, $torrent_pass, $Enabled, $Paranoia, $Invites, $DisableLeech, $Visible, $BonusPoints, $IRCLines, $JoinDate, $Info, $Avatar, $AdminComment, $Donor, $Artist, $Warned, $SupportFor, $RestrictedForums, $PermittedForums, $InviterID, $InviterName, $ForumPosts, $RatioWatchEnds, $RatioWatchDownload, $DisableAvatar, $DisableInvites, $DisablePosting, $DisableForums, $DisableTagging, $DisableUpload, $DisableWiki, $DisablePM, $DisablePoints, $DisablePromotion, $DisableIRC, $DisableRequests, $FLTokens, $CommentHash, $InfoTitle, $LockedAccount) = $DB->next_record(MYSQLI_NUM, array(8, 11));
88 89
 } else { // Person viewing is a normal user
89 90
   $DB->query("
90 91
     SELECT
@@ -107,6 +108,7 @@ if (check_perms('users_mod')) { // Person viewing is a staff member
107 108
       i.Avatar,
108 109
       m.FLTokens,
109 110
       m.BonusPoints,
111
+      m.IRCLines,
110 112
       i.Donor,
111 113
       i.Warned,
112 114
       COUNT(posts.id) AS ForumPosts,
@@ -128,7 +130,7 @@ if (check_perms('users_mod')) { // Person viewing is a staff member
128 130
 
129 131
     list($Username, $Email, $LastAccess, $IP, $Class, $Uploaded, $Downloaded,
130 132
 $RequiredRatio, $Enabled, $Paranoia, $Invites, $CustomTitle, $torrent_pass,
131
-$DisableLeech, $JoinDate, $Info, $Avatar, $FLTokens, $BonusPoints, $Donor, $Warned,
133
+$DisableLeech, $JoinDate, $Info, $Avatar, $FLTokens, $BonusPoints, $IRCLines, $Donor, $Warned,
132 134
 $ForumPosts, $InviterID, $DisableInvites, $InviterName, $InfoTitle) = $DB->next_record(MYSQLI_NUM, array(9, 11));
133 135
 }
134 136
 $Email = apc_exists('DBKEY') ? DBCrypt::decrypt($Email) : '[Encrypted]';

Loading…
Cancel
Save