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
Letter Statistics in Member Profile v1.0 Details »»
Letter Statistics in Member Profile v1.0
Version: 1.00, by Sho Sho is offline
Developer Last Online: Nov 2023 Show Printable Version Email this Page

Version: 2.3.x Rating:
Released: 03-15-2003 Last Update: Never Installs: 12
 
No support by the author.

This hack will add several new statistics to your member's profile pages:

- The number of letters all his/her posts contain.
- The average number of letters he/she posts per day.
- His/her percentage of all letters in all posts in the database.
- The average number of letters a post by him/her contains.


File Modifications: 1 (member.php)
Template Modifications: 1 (getinfo)


This hack was tested with vBulletin 2.2.7 and 2.3.0 Release Candidate 3. I'm confident it will work with every version of vBulletin in the 2.2.x branch. Probably even with older versions.


Two screenshots of the hack in action are included in the ZIP archive:

screenshot1.gif: Plain vBulletin 2.3.0 RC3.
screenshot2.gif: My own forums, a heavily modified vBulletin 2.2.7 translated into German (hack's in English, though).


Special thanks to Logician for helping with the SQL syntax used in this hack.


Have fun with it!

Show Your Support

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

Comments
  #12  
Old 03-19-2003, 12:23 PM
zajako's Avatar
zajako zajako is offline
 
Join Date: Jan 2002
Location: a place not to far away
Posts: 633
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

nice hack ill post a hack based of your query for forumhome.
Reply With Quote
  #13  
Old 03-19-2003, 01:06 PM
Sho Sho is offline
 
Join Date: Nov 2001
Location: Berlin, Germany
Posts: 155
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Sure, go ahead. Mentioning me & Logician would be cool, though. And a link to this hack?
Reply With Quote
  #14  
Old 03-19-2003, 01:24 PM
Xenon's Avatar
Xenon Xenon is offline
 
Join Date: Oct 2001
Location: Bavaria
Posts: 12,878
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

hmm, your profile page loads quite slow...

Quote:
So it's a SUM(LENGTH(pagetext)) for the table "post" WHERE userid=X.
yes you are right here, that part should be relativ fast
but for getting the global percentage you need also that query:
Quote:
So it's a SUM(LENGTH(pagetext)) for the whole table "post"
which will become slower and slower how more posts you have.
ok, getprofile isn't called so often, but also there i don't think that's such a good way.
i'd use a sort of caching the absulote letter ammount and just update it rarely
Reply With Quote
  #15  
Old 03-19-2003, 01:28 PM
Sho Sho is offline
 
Join Date: Nov 2001
Location: Berlin, Germany
Posts: 155
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'd hate having to do that manually by loading up a script, and I don't have access to the crontab task scheduler, so I prefer doing it dynamically.

Yep, my profile pages load quite slow, mostly because this is just a small part of a shared server and really underpowered. The letter statistics do not account for a major part of the generation time, though. Granted, that's because there are some other modifications in there.

Overall, I think it's the best way to do it in a case similar to mine.
Reply With Quote
  #16  
Old 03-19-2003, 01:34 PM
Xenon's Avatar
Xenon Xenon is offline
 
Join Date: Oct 2001
Location: Bavaria
Posts: 12,878
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

you can do it 'nearly' dynamically without having acces to a crontab scheduler

but i'll leave it up to you

just as a hint, look at the cached birthdays on forumhome
Reply With Quote
  #17  
Old 03-19-2003, 01:37 PM
Sho Sho is offline
 
Join Date: Nov 2001
Location: Berlin, Germany
Posts: 155
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Alright, gonna do that.

I also want to look at your forumhome optimization hack on the weekend, caching the moderators sounds like a nice idea.
Reply With Quote
  #18  
Old 03-19-2003, 01:56 PM
Xenon's Avatar
Xenon Xenon is offline
 
Join Date: Oct 2001
Location: Bavaria
Posts: 12,878
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

thx

i currently have a chaching hype
Reply With Quote
  #19  
Old 03-19-2003, 02:43 PM
Xenon's Avatar
Xenon Xenon is offline
 
Join Date: Oct 2001
Location: Bavaria
Posts: 12,878
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

https://vborg.vbsupport.ru/showthrea...297#post369297

i'm sure it can help you, too from what i know
Reply With Quote
  #20  
Old 04-09-2003, 02:02 PM
Entourage Entourage is offline
 
Join Date: Apr 2002
Posts: 42
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Nice hack! installe whas super easy, works great, tnx!
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 03:43 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.04270 seconds
  • Memory Usage 2,290KB
  • Queries Executed 26 (?)
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
  • (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
  • (1)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (9)postbit
  • (10)postbit_onlinestatus
  • (10)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_postinfo_query
  • fetch_postinfo
  • 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