Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Full Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Forum Quick Stats v1.0 Details »»
Forum Quick Stats v1.0
Version: 1.00, by Boofo Boofo is offline
Developer Last Online: Jun 2012 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 05-18-2003 Last Update: Never Installs: 59
 
No support by the author.

Forum Quick Stats v1.0
(By Boofo)

Thanks goes out to Mug and cirisme, for all of their indispensable help with the queries. Without them, this hack would still be on the drawing board. And thanks also goes out to Grog6 for the basis of this hack, which is his Forums Statistics hack. A special thanks goes out to Logician for his great Last Post Minute Hack. Thank you, my friend.

This hack has all new 100% working (and optimized) queries. I will be updating it to cache all of the queries so it will only update them at a pre-determined time (set by you).

What this hack does:
It will display stats about each forum at the top of that forum. (NOTE: The attachments info will NOT show in forums that have no attachments.) Also included in the hack is Logician's "Last Post Minute Hack" (with his permission, of course). This hack will display a link the last post and the time the last post was made (i.e. "1 minute" or "2 days", etc.).

Tested and installed on vBulletin v2.2.9 (but should work with all versions).

Files to edit: 1 (forumdisplay.php)
Template to edit: 1 (forumdisplay)
Templates to add: 2 (lastpostminute and forumdisplay_quickstats)
Settings to edit: 1 (in the Admin CP)
Install time: 5 minutes (if you are slow or a newbie )

[high]Please click the install button if you install this hack. (I have 3 kids to put through college.)[/high]

Show Your Support

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

Comments
  #12  
Old 05-19-2003, 11:39 PM
Reverend Reverend is offline
 
Join Date: Mar 2002
Location: England
Posts: 206
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Now installed on vb 2.3.0.
Works perfect.
One question,how do i change the font color for "$yourstats"

i tried editing the forumdisplay.php code from this:

<smallfont><b>$bbuserinfo[username], you have made a total of <i>$yourposts</i> posts in this forum.</b></smallfont>

to this:

<smallfontcolor="#FFFFFF"><b>$bbuserinfo[username], you have made a total of <i>$yourposts</i> posts in this forum.</b></smallfont>

but get parse errors.
Reply With Quote
  #13  
Old 05-19-2003, 11:41 PM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Change this:

<smallfontcolor="#FFFFFF"><b>$bbuserinfo[username], you have made a total of <i>$yourposts</i> posts in this forum.</b></smallfont>

to this:

<smallfontcolor=\"#FFFFFF\"><b>$bbuserinfo[username], you have made a total of <i>$yourposts</i> posts in this forum.</b></smallfont>

You have to put backslashes before the quotes in php files.
Reply With Quote
  #14  
Old 05-19-2003, 11:47 PM
Reverend Reverend is offline
 
Join Date: Mar 2002
Location: England
Posts: 206
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

That did it.
Thanks Boofo.
Reply With Quote
  #15  
Old 05-19-2003, 11:53 PM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

No problem. Enjoy!
Reply With Quote
  #16  
Old 05-19-2003, 11:54 PM
Reverend Reverend is offline
 
Join Date: Mar 2002
Location: England
Posts: 206
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Just wondering if its possible to edit the font colour for $yourstats via the forumdisplay_quickstats template so that the colour can be set for different styles.
Reply With Quote
  #17  
Old 05-20-2003, 12:19 AM
squawell's Avatar
squawell squawell is offline
 
Join Date: Oct 2001
Posts: 681
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Boofo if i want forum member just see their own stats....how

should i do??(the attachment part)...thankz...
Reply With Quote
  #18  
Old 05-20-2003, 01:40 AM
Smoothie Smoothie is offline
 
Join Date: Oct 2001
Location: New York
Posts: 1,834
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

number of queries this adds?
Reply With Quote
  #19  
Old 05-20-2003, 01:48 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Today at 08:19 PM squawell said this in Post #16
Boofo if i want forum member just see their own stats....how

should i do??(the attachment part)...thankz...
That would require re-writing the whole hack. The only problem you might have in doing it that way would be if you get a user in a forum that they haven't done a whole lot in, the information would be very low.
Reply With Quote
  #20  
Old 05-20-2003, 01:54 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Today at 09:40 PM Smoothie said this in Post #17
number of queries this adds?
Right now it adds 7 queries (8 with Logician's hack). The old Forum Statistics hack added 6 queries and didn't have the attachments info, Logician's Lastpostminute hack, "your stats" or the last poster. I am in the process of writing the code that will cache those queries and only run them every so many minutes (i.e. 10) in which case it will run 8 queries when it is updating the cache and only one query when it is not. How does that sound?
Reply With Quote
  #21  
Old 05-20-2003, 02:18 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Today at 07:54 PM Reverend said this in Post #15
Just wondering if its possible to edit the font colour for $yourstats via the forumdisplay_quickstats template so that the colour can be set for different styles.
Yes, you can, but it will show the thread and posts numbers in the your stats line at the bottom of the box even if they haven't posted in that thread. Here is how you can do it:

In forumdisplay.php, find:

PHP Code:
if ($yourposts !="0") {
$yourstats "<tr id=\"cat\">
        <td bgcolor=\"#1D6AA0\" align=\"center\" nowrap colspan=\"3\"><smallfont><b>
$bbuserinfo[username], you have made a total of <i>$yourposts</i> in this forum. (<i>$yourthreads</i> and <i>$yourreplies</i>)</b></smallfont></td>
</tr>"
;
} else {
$yourstats "<tr id=\"cat\">
        <td bgcolor=\"#1D6AA0\" align=\"center\" nowrap colspan=\"3\"><smallfont><b>
$bbuserinfo[username], you have made a total of <i>$yourposts</i> posts in this forum.</b></smallfont></td>
</tr>"
;

and delete it. Then go into the forumdisplay_quickstats template and replace:

PHP Code:
$yourstats 
with this:

PHP Code:
<tr id="cat">
        <
td bgcolor="#1D6AA0" align="center" nowrap colspan="3"><smallfont><b>$bbuserinfo[username], you have made a total of <i>$yourposts</iin this forum. (<i>$yourthreads</i> and <i>$yourreplies</i>)</b></smallfont></td>
</
tr
That should do it.
Reply With Quote
Reply


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 07:39 PM.


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.08685 seconds
  • Memory Usage 2,320KB
  • 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
  • (3)bbcode_php
  • (3)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
  • (11)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
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete