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
       <div class="head colhead_dark">Community</div>
36
       <div class="head colhead_dark">Community</div>
37
       <ul class="stats nobullet">
37
       <ul class="stats nobullet">
38
         <li id="comm_posts">Forum posts: <?=number_format($ForumPosts)?> <a href="userhistory.php?action=posts&amp;userid=<?=$UserID?>" class="brackets">View</a></li>
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
 <?  if ($Override = check_paranoia_here('torrentcomments+')) { ?>
40
 <?  if ($Override = check_paranoia_here('torrentcomments+')) { ?>
40
         <li id="comm_torrcomm"<?=($Override === 2 ? ' class="paranoia_override"' : '')?>>Torrent comments: <?=number_format($NumComments)?>
41
         <li id="comm_torrcomm"<?=($Override === 2 ? ' class="paranoia_override"' : '')?>>Torrent comments: <?=number_format($NumComments)?>
41
 <?        if ($Override = check_paranoia_here('torrentcomments')) { ?>
42
 <?        if ($Override = check_paranoia_here('torrentcomments')) { ?>

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

40
       m.can_leech,
40
       m.can_leech,
41
       m.Visible,
41
       m.Visible,
42
       m.BonusPoints,
42
       m.BonusPoints,
43
+      m.IRCLines,
43
       i.JoinDate,
44
       i.JoinDate,
44
       i.Info,
45
       i.Info,
45
       i.Avatar,
46
       i.Avatar,
84
     header("Location: log.php?search=User+$UserID");
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
 } else { // Person viewing is a normal user
89
 } else { // Person viewing is a normal user
89
   $DB->query("
90
   $DB->query("
90
     SELECT
91
     SELECT
107
       i.Avatar,
108
       i.Avatar,
108
       m.FLTokens,
109
       m.FLTokens,
109
       m.BonusPoints,
110
       m.BonusPoints,
111
+      m.IRCLines,
110
       i.Donor,
112
       i.Donor,
111
       i.Warned,
113
       i.Warned,
112
       COUNT(posts.id) AS ForumPosts,
114
       COUNT(posts.id) AS ForumPosts,
128
 
130
 
129
     list($Username, $Email, $LastAccess, $IP, $Class, $Uploaded, $Downloaded,
131
     list($Username, $Email, $LastAccess, $IP, $Class, $Uploaded, $Downloaded,
130
 $RequiredRatio, $Enabled, $Paranoia, $Invites, $CustomTitle, $torrent_pass,
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
 $ForumPosts, $InviterID, $DisableInvites, $InviterName, $InfoTitle) = $DB->next_record(MYSQLI_NUM, array(9, 11));
134
 $ForumPosts, $InviterID, $DisableInvites, $InviterName, $InfoTitle) = $DB->next_record(MYSQLI_NUM, array(9, 11));
133
 }
135
 }
134
 $Email = apc_exists('DBKEY') ? DBCrypt::decrypt($Email) : '[Encrypted]';
136
 $Email = apc_exists('DBKEY') ? DBCrypt::decrypt($Email) : '[Encrypted]';

Loading…
Cancel
Save