Top Posters Block

  Post new topicReply to topicPrintable Version
<< View previous topic View next topic >>
Share: Del.icio.us  Digg  Google  Spurl  Blink  Furl  Y! MyWeb  
#1   Top Posters Block
Spyder
CZ Newbie
Spyder has been a member for over 20 year's 20 Year Member
Status: Offline
Joined: Feb 28, 2004
0.00 posts per day
Posts: 16
Points: 740
   
I want my Top 5 Posters Block to look like the one at this site [ Register or login to view links on this board. ] does anyone now where I can download it or can someone tell me what I have to edit. The one I have it has name, posts and number of posts on three separate lines and there not lined up like that one is. Heres the code to the block:


<?php

/************************************************************************/
/* PHP-NUKE: Web Portal System                                          */
/* ===========================                                          */
/*                                                                      */
/* Copyright (c) 2002 by Francisco Burzi (fbc@mandrakesoft.com)         */
/* http://phpnuke.org                                                   */
/*                                                                      */
/* This program is free software. You can redistribute it and/or modify */
/* it under the terms of the GNU General Public License as published by */
/* the Free Software Foundation; either version 2 of the License.       */
/************************************************************************/
/************************************************************************/
/* block-Top_Posters.php                                                */
/* ===========================                                          */
/*                                                                      */
/* Copyright (c) 2003 by chatserv (chatserv@nukeresources.com)          */
/* http://nukeresources.com                                             */
/************************************************************************/
/* Cosmetic changes by dvsDave at [ Register or login to view links on this board. ]             */
/* http://controlbooth.com                                              */
/************************************************************************/

if (eregi("block-Top_Posters.php", $_SERVER['PHP_SELF'])) {
    Header("Location: index.php");
    die();
}
$a = 1;
    global $user, $cookie, $sitename, $prefix, $user_prefix, $dbi, $admin, $module_name;
    $result=sql_query("SELECT user_id, username, user_posts, user_avatar FROM ".$user_prefix."_users ORDER BY user_posts DESC LIMIT 0,5", $dbi);
    while(list($user_id, $username, $user_posts, $user_avatar) = sql_fetch_row($result, $dbi)) {
$content .= "<div align=\"left\"><table class=\"outer\" cellpadding=\"0\" style=\"border-collapse: collapse\" bordercolor=\"#CCCCCC\" cellspacing=\"1\" border=\"0\">";
$content .= "<tr class=\"even\" vAlign=\"middle\">";

$content .= "<td align=\"middle\">";
if (eregi("http://", $user_avatar)) {
$content .= "&nbsp;&nbsp;<a href=\"modules.php?name=Forums&amp;file=profile&amp;mode=viewprofile&amp;u=$user_id\"><img alt src=\"$user_avatar\" border =\"0\" width=\"55\"></a></td>";
}
else
$content .= "&nbsp;&nbsp;<a href=\"modules.php?name=Forums&amp;file=profile&amp;mode=viewprofile&amp;u=$user_id\"><img alt src=\"modules/Forums/images/avatars/$user_avatar\" border =\"0\" width=\"55\"></a></td>";
$content .= "<td align=\"middle\">&nbsp;<a href=\"modules.php?name=Forums&amp;file=profile&amp;mode=viewprofile&amp;u=$user_id\"><b>$username</b></a>&nbsp;<br>&nbsp;<a href=\"modules.php?name=Forums&amp;file=search&amp;search_author=$username\">Posts:</a>&nbsp;<br>";
$content .= "&nbsp;<a href=\"modules.php?name=Forums&amp;file=search&amp;search_author=$username\">$user_posts</a>&nbsp;</td>";
$content .= "</tr>";
$content .= "</table></div><hr>";
}

?>



Back to top Reply with quote
#2   re: Top Posters Block
19delta
CZ Super Newbie
19delta has been a member for over 20 year's 20 Year Member
Occupation: Military Police Officer
Gender: Male
Website:
Status: Offline
Joined: Jan 04, 2004
0.01 posts per day
Posts: 74
Points: 18,002
 Yahoo Messenger MSN Messenger ICQ Number
Here is the link on this site:
[ Register or login to view links on this board. ]



Back to top Reply with quote
#3   re: Top Posters Block
Spyder
CZ Newbie
Spyder has been a member for over 20 year's 20 Year Member
Status: Offline
Joined: Feb 28, 2004
0.00 posts per day
Posts: 16
Points: 740
   
I wanted the one that shows up on the front page of the site, I tried changing the file myself but I get parse errors. Could someone edit the code for me? icon_redface.gif



Back to top Reply with quote
Display posts from previous:      
Add To: Del.icio.us  Digg  Google  Spurl  Blink  Furl  Y! MyWeb  
<< View previous topic View next topic >>
Post new topicReply to topic

Jump to 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum