Welcome, Guest. Please Login or Register.
July 02, 2024, 11:47:21 PM
Home Help Search Log in Register
News: If you are still using YaBB SE, please consider upgrading to SMF as soon as possible.

YaBB SE Community  |  Development  |  Mod Ideas and Creation  |  Cut down topic summary... « previous next »
Pages: [1] Reply Ignore Print
Author Topic: Cut down topic summary...  (Read 1565 times)
Enc0der
Jr. Member
**
Posts: 90


I love YaBB SE!

WWW
Cut down topic summary...
« on: December 31, 2001, 09:39:01 AM »
Reply with quote

The topic summary is one heck of a bandwidth killer.. :)

Can someone please make a mod that shows only X messages on the topic summary ?
let's say... the last 5 messages?


here's the full code:
function doshowthread (){
   global $censored,$threadid,$enable_ubbc,$txt,$color,$db_prefix,$realNames;
   # Load Censor List
   LoadCensorList();
   $request = mysql_query("SELECT posterName,posterTime,body,smiliesEnabled FROM {$db_prefix}messages WHERE ID_TOPIC='$threadid' ORDER BY ID_MSG DESC");
   if (mysql_num_rows($request)!=0) {
      print <<<EOT
   <BR><BR>
   <table cellspacing=1 cellpadding=0 width="98%" align="center" bgcolor="$color[bordercolor]" class="bordercolor">
   <tr><td>
   <table class="windowbg" cellspacing="1" cellpadding="2" width="100%" align="center" bgcolor="$color[windowbg]">
   <tr><td class="titlebg" bgcolor="$color[titlebg]" colspan=2><font size=2 class="text1" color="$color[titletext]">
   <b>$txt[468]</b></font>
   </td></tr>
EOT;
      while (list ($tempname,$tempdate,$message,$es) = mysql_fetch_row($request))
      {
         LoadRealName($tempname);
         $tempdate = timeformat($tempdate);

         foreach ($censored as $tmpa => $tmpb)
            $message = str_replace($tmpa,$tmpb,$message);
         if($enable_ubbc) { $message = DoUBBC($message,$es); }
         print <<<EOT

<tr><td align=left class="catbg">
<font size=1>$txt[279]: $realNames[$tempname]</font></td>
<td class="catbg" align=right>
<font size=1>$txt[280]: $tempdate</font></td>
</tr>
<tr><td class="windowbg2" colspan=2 bgcolor="$color[windowbg2]">
<font size=1>$message</font>
</td></tr>
EOT;
      }
      print "</table></td></tr></table>\n";
   }
   else { print "<!--no summary-->"; }
}
Logged
Enc0der
Jr. Member
**
Posts: 90


I love YaBB SE!

WWW
Re:Cut down topic summary...
« Reply #1 on: January 03, 2002, 01:37:17 PM »
Reply with quote

 ???

 :)
Logged
Joseph Fung
Global Moderator
YaBB God
*****
Posts: 4512


Keep smiling: it makes others nervous.

WWW
Re:Cut down topic summary...
« Reply #2 on: January 03, 2002, 02:14:59 PM »
Reply with quote

oh yeah - forgot to mention...you can now specify how many messages to display (a -ve number for all of them)
Logged

Enc0der
Jr. Member
**
Posts: 90


I love YaBB SE!

WWW
Re:Cut down topic summary...
« Reply #3 on: January 03, 2002, 02:59:07 PM »
Reply with quote

where?
Logged
Joseph Fung
Global Moderator
YaBB God
*****
Posts: 4512


Keep smiling: it makes others nervous.

WWW
Re:Cut down topic summary...
« Reply #4 on: January 03, 2002, 03:09:44 PM »
Reply with quote

It hasn't been released yet.
Logged

Enc0der
Jr. Member
**
Posts: 90


I love YaBB SE!

WWW
Re:Cut down topic summary...
« Reply #5 on: January 03, 2002, 03:14:19 PM »
Reply with quote

oh, ok..  8)
Logged
Michael
YaBB God
*****
Posts: 782


Recursion \Re*cur"sion\, n. - See recursion.

ICQ - 47769041mrtorrent@hotmail.com WWW
Re:Cut down topic summary...
« Reply #6 on: January 03, 2002, 06:08:41 PM »
Reply with quote

Sweet. ;D I'd started doing this for Y1G (there wasn't a mod for this out, was there?), but since I plan on switching to SE, I think I'll just stop before I hurt my tiny brain...
Logged

~ Michael ~
--------------
The MikeCam
I went to the Net and all I got was this stupid tagline.
klumy
Sr. Member
****
Posts: 432


Re:Cut down topic summary...
« Reply #7 on: January 03, 2002, 08:16:39 PM »
Reply with quote

this one is a very useful MOD !!
Hope you will implement it soon ;)
Logged
Pages: [1] Reply Ignore Print 
YaBB SE Community  |  Development  |  Mod Ideas and Creation  |  Cut down topic summary... « previous - next »
 


Powered by MySQL Powered by PHP YaBB SE Community | Powered by YaBB SE
© 2001-2003, YaBB SE Dev Team. All Rights Reserved.
SMF 2.1.4 © 2023, Simple Machines
Valid XHTML 1.0! Valid CSS

Page created in 0.080 seconds with 21 queries.