Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Full Releases

Reply
 
Thread Tools
Details »»

Version: , by (Guest)
Developer Last Online: Jan 1970 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 09-19-2001 Last Update: Never Installs: 19
 
No support by the author.

I updated the hack a little so it looks nice.

http://vbulletin.com/forum/showthrea...272#post173883

Credit To: ethank

Added:

Display order, so it orders the sub-forums the way they are listed in your admin CP.

Added an hr.

Thats it it!

if you watn the HR to look good add this into your
"Custom replacements"

hr is replaced by <hr size="1" color="{ tablebordercolor }"

{ tablebordercolor } - dont forget to remove the spaces "{ }

that is it!

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #82  
Old 02-14-2003, 03:29 PM
sonic3d's Avatar
sonic3d sonic3d is offline
 
Join Date: Jan 2002
Location: Chicago
Posts: 301
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

can some1 make it so that it doesn't follow behind the descritpions but on its own.

l8er
sonic
Reply With Quote
  #83  
Old 02-15-2003, 06:47 PM
Brain Crusher Brain Crusher is offline
 
Join Date: Feb 2003
Posts: 26
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by george_proost
?0.02

I used the basis of the hack. Modified extremely... and works great. Does not generate many extra queries, and is damn fast.

Features added :
- Bold on new messages
- custom forum type
- variable number of columns to display per parents children

added 2 fields to forum table showas and numcols
this is the index.php version.
Can you post a code to insert the two fields with php mysql admin? I don?t know must be the fields a smallint(6) or a mediumint(8) or...?
Reply With Quote
  #84  
Old 02-15-2003, 07:29 PM
Brain Crusher Brain Crusher is offline
 
Join Date: Feb 2003
Posts: 26
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by george_proost
?0.02

I used the basis of the hack. Modified extremely... and works great. Does not generate many extra queries, and is damn fast.

Features added :
- Bold on new messages
- custom forum type
- variable number of columns to display per parents children

added 2 fields to forum table showas and numcols
this is the index.php version. For the forumdisplay.php
there is some stuff to comment out ( or in) dependeing on your requirements (sorts out spacing before and after subforum lists)

See it in action at www.mainframeforum.com

here is the code, I do not support it, have fun .....
PHP Code:
// ********************************************************************
// ADDED BY ERK 
// ********************************************************************
$subforums=$DB_site->query("select title,forumid,lastpost,replycount,threadcount,showas,numcols from forum where parentid = $forum[forumid] and active != 0 ORDER BY parentid,displayorder"); 
if (
$DB_site->num_rows($subforums)>0
  { 
  
$subs "<smallfont><table width=\"100%\" cellpadding=\"0\" cellspacing=\"0\" border=\"0\" align=\"center\" id=\"ltlink\" ><tr valign=\"top\"> "

  
$num_cols  $forum[numcols];
  
$col_width floor(100/$num_cols);  
  
$num_rows  ceil($DB_site->num_rows($subforums)/$num_cols);
  
$cur_col   0;
  
$cur_row   1;

  while (
$forum_child=$DB_site->fetch_array($subforums)) 
    { 
    
$permission=$DB_site->query_first("select accessmask from access where userid = $bbuserinfo[userid] AND forumid = $forum_child[forumid]"); 
    if (
$permission['accessmask'] != || $permission['accessmask'] == null
      { 
      
// ------------------------------
      // check new messages in subforum
      // and set 'bolding' attributes
      // ------------------------------
        
$bold_on "";
        
$bold_off ""
        if (
$bbuserinfo['lastvisitdate']=='Never') {
          
$bold_on "<b>";
          
$bold_off "</b>";
         } else {
           if (isset(
$bbforumview[$forum_child['forumid']]) and $bbforumview[$forum_child['forumid']]>$bbuserinfo['lastvisit']) {                $userlastvisit=$bbforumview[$forum_child['forumid']];
            } else {
                
$userlastvisit=$bbuserinfo['lastvisit'];
            }
        if (
$userlastvisit<$forum_child['lastpost']) {
          
$bold_on "<b>";
          
$bold_off "</b>";
        } else {
          
$bold_on "";
          
$bold_off "";
        }
      }

    if (
$cur_row == 1)
        {
        
$subs.="<td width=\"$col_width%\">";
    
        
$cur_col++;
        }
    
$subs.="<table cellspacing=\"0\" cellpadding=\"1\" border=\"0\" width=\"100%\"><tr valign=\"top\" ><td nowrap><font class=\"sf\">- </td><td width=\"100%\">";
    
$subs.="<a href=\"$bburl/f$forum_child[forumid]/s\">";
    
$child_text "$bold_on$forum_child[title]$bold_off&nbsp;"

    
// switch on showas
    
switch ($forum_child[showas])
    {
    
//  FULL AFFILIATES 
    
case "AFF":
      
$subs.="<font class=\"sf\" color=\"darkblue\">$child_text</font></a><img src=\"$bburl/images/star.gif\">";  
      break;
    case 
"AFF_AS":
      
$subs.="<font class=\"sf\" color=\"white\">$child_text</font></a><img src=\"$bburl/images/star.gif\">";  
      break;
    
//  VENDOR MODERATED
    
case "VEN":
        
$subs.="<font class=\"sf\" color=\"black\">$child_text</font></a><img src=\"$bburl/images/posticonnew.gif\">";
      break;  
    
//  CONTRIBUTOR MODERATED
    
case "CON":
      
$subs.="<font class=\"sf\" color=\"darkgreen\">$child_text</font></a><img src=\"$bburl/images/paperclip.gif\">";   
      break;
    
//  USENET FORUM ENTRIES
    
case "USE":
      
$subs.="<font class=\"sf\" color=\"brown\">$child_text</font></a><img src=\"$bburl/images/posticon.gif\">";
      break;
    
//  MEMBER MODERATED
    
case "MEM":
      
$subs.="<font class=\"sf\" color=\"darkorange\">$child_text</font></a>";  
      break;
    
//  HIDDEN 
    
case "LOW":
      
$subs.="<font class=\"sf\" color=\"#999999\">$child_text</font></a>"
      break;
    
//  DEFAULT
    
default:
      
// ------------------------------- 
      // set entry to italic if no posts
      // -------------------------------
      // if ($forum_child[threadcount] == 0 ){
      //   $subs.="<font class=\"sf\" color=\"black\"><i>$child_text</i></font></a>";  
      // } else {
        
$subs.="<font class=\"sf\" color=\"black\">$child_text</font></a>"
      
// }      
      
break; 
    } 
// end switch

    // ---------------------
    // tag on the replycount
    // ---------------------
    // if ($forum_child[threadcount] > 0 ){
    //  $subs.="<font class=\"sf\" color=\"#999999\">&nbsp;&nbsp;<i>Posts($forum_child[replycount])</i></font>";
    // }

    // ---------------------------------------
    // check if i need to go to new column yet
    // ---------------------------------------
    
if ($cur_row == $num_rows) { 
      
$cur_row=1$subs.= "</td></tr></table></td>";
      }
    else {
      
$cur_row++; 
      
$subs.="</td></tr></table>";
      }
    
  } 
// end-if 
}  // end-while

  // -------------------------------------  
  // close off the remaining empty columns
  // and finish off the table etc..
  // -------------------------------------
  
$todo_cols $num_cols $cur_col;
  while (
$todo_cols != 0)
  {
    
$subs.="<td width=\"$col_width%\"></td>" ;
    
$todo_cols--;
  }
  
$subs.="</tr></table></smallfont>";
  
  if (
$forum['description'] != '') {
    
$forum['description'].= "<br><br>$subs<br>";                
    }
  else {
    
$forum['description'].= "<br>$subs";                  // used in index.php
    // $forum['description'].= "<br>$subs<br>";                 // used in forumdisplay.php
    
}

  
$subs=null;
// end-if
else {
  
 if (
$forum['description'] != '') {
  
//  $forum['description'].= "<br><br>";                     // used in forumdisplay.php 
 

  else  {
  
// $forum['description'].= "<br>";                     // used in forumdisplay.php 
  
}

}

$DB_site->free_result($subforums); 
$forum_child=null;
 
// ********************************************************************
// END ADDED
// ******************************************************************** 
Warning: Division by zero in /usr/local/httpd/htdocs/kunden/web14/html/forum/index.php on line 344

Warning: Division by zero in /usr/local/httpd/htdocs/kunden/web14/html/forum/index.php on line 345

Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to allocate 20 bytes) in /usr/local/httpd/htdocs/kunden/web14/html/forum/index.php on line 456

This sucks, help me !
Reply With Quote
  #85  
Old 02-16-2003, 05:51 PM
sonic3d's Avatar
sonic3d sonic3d is offline
 
Join Date: Jan 2002
Location: Chicago
Posts: 301
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

can ne1 help me?
Reply With Quote
  #86  
Old 03-09-2003, 06:24 PM
Cyn Cyn is offline
 
Join Date: Apr 2002
Posts: 157
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'd like to use this but have a problem I can't pinpoint. The subforum titles appear hyperlinked in the parent forum title on the home page BUT it looks like this:

Subforum1 Subforum2 Subforum3"> ParentForum

It looks just like that with the subforums in color and the "> and the parent forum title in black.

Why would it put the Parent forum title at the end? And why the " and the > ?
Reply With Quote
  #87  
Old 09-02-2003, 08:07 PM
Megadeuce Megadeuce is offline
 
Join Date: Jul 2003
Location: League City, Texas USA
Posts: 78
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Works great
Reply With Quote
  #88  
Old 09-03-2003, 04:34 AM
Bison's Avatar
Bison Bison is offline
 
Join Date: Jun 2002
Location: Virginia Beach, Virginia
Posts: 522
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

There's another hack that doesn't add "One Query" to your forum!
Reply With Quote
  #89  
Old 09-14-2003, 03:29 AM
MaDCaT75 MaDCaT75 is offline
 
Join Date: Jul 2003
Location: Southern California
Posts: 718
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I tried to view the demo but it said I had no permission?
Reply With Quote
  #90  
Old 10-03-2003, 04:17 AM
deathemperor's Avatar
deathemperor deathemperor is offline
 
Join Date: Jul 2003
Location: HOL
Posts: 1,270
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

hi there, need help ^ ^
the sub-forums in the forum home show well, but my problem is those sub-forums didnt have a hyperlink to them so that after i added this, it is just only to show the name of the sub-forums ( cant access them in the forum home, there is NO links )
slove me this please
Reply With Quote
  #91  
Old 10-19-2003, 03:53 PM
X-Sector X-Sector is offline
 
Join Date: Oct 2003
Posts: 154
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Awesome hack man
Reply With Quote
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 08:12 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.06285 seconds
  • Memory Usage 2,351KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)bbcode_php
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (10)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • postbit_imicons
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete