Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.5 > vBulletin 3.5 Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Average age in forumhome Details »»
Average age in forumhome
Version: 1.03, by Lea Verou Lea Verou is offline
Developer Last Online: Jul 2012 Show Printable Version Email this Page

Version: 3.5.3 Rating:
Released: 10-24-2005 Last Update: 10-24-2005 Installs: 59
Uses Plugins Template Edits
 
No support by the author.

This is a modification I really wanted for my forum and I am posting it cause I thought that others may find it useful as well. However, I only had the idea as Xenon helped my really much with the query (My SQL knowledge is very basic and this is why this hack isn't supported, I wish I could support it but I don't have the knowledge to do so).
Thanks also to tamarian for fixing the issue with the table prefix.

Instructions


1. Import the attached XML file. It's a plugin, not a product
2. Edit template FORUMHOME:
Find:
HTML Code:
<span title="<phrase 1="$vboptions[activememberdays]">$vbphrase[within_the_last_x_days]</phrase>">$vbphrase[active_members]: $activemembers</span>
                </if>
Add below:
HTML Code:
Average Age: $avg_age
You're done!
If you liked this and you are using it, don't forget to click INSTALL!

If you want less or more than 2 decimals at the average then:
  • In the plugin manager click Avg Age in order to edit the plugin code.
  • Find DAYOFYEAR(NOW())) / 365), 2) and change the 2 in green to the number of decimals you like.

Supporters / CoAuthors

Show Your Support

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

Comments
  #12  
Old 10-26-2005, 08:25 AM
Snake's Avatar
Snake Snake is offline
 
Join Date: Mar 2005
Location: Cleveland, OH
Posts: 3,832
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Installed!
Reply With Quote
  #13  
Old 10-26-2005, 09:37 AM
Lea Verou Lea Verou is offline
 
Join Date: Jul 2005
Location: Greece
Posts: 1,856
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Aftermath
Installed!
Quote:
If you liked this and you are using it, don't forget to click INSTALL!
Reply With Quote
  #14  
Old 10-26-2005, 10:04 AM
weaver weaver is offline
 
Join Date: Mar 2004
Posts: 183
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

How would you integrate this with vbadvanced? I found the template to insert it into but it's not showing a value for age.
Reply With Quote
  #15  
Old 10-29-2005, 10:16 AM
Lea Verou Lea Verou is offline
 
Join Date: Jul 2005
Location: Greece
Posts: 1,856
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by weaver
How would you integrate this with vbadvanced? I found the template to insert it into but it's not showing a value for age.
Woops sorry I took so long to respond, I didn't notice your message!
What do you mean "integrate it with vbadvanced"? You want it to show in the stats block?
Also, the most common reasons for it not showing a value for age:
1. You haven't done the template change correctly
2. The plugin isn't enabled
3. If you have the very first version of the hack, you haven't entered the database perfix correctly (if that's the case you would get a db error as well)

Do you get any errors or the number just doesn't show?
Reply With Quote
  #16  
Old 12-24-2005, 11:14 PM
Julie's Avatar
Julie Julie is offline
 
Join Date: Mar 2005
Location: Oslo, Norway
Posts: 187
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hm, funny little thing this Thanks!

*installs*
Reply With Quote
  #17  
Old 12-24-2005, 11:23 PM
Lea Verou Lea Verou is offline
 
Join Date: Jul 2005
Location: Greece
Posts: 1,856
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thank you
What is funnier is the way I came up with it!
Some people (a very annoying competitor as well) that had only seen a little of my forum were saying that it has a very low level of average age which I knew was not true. So I put that in the forumhome and when they saw average age 29 they shut their mouths
Reply With Quote
  #18  
Old 12-24-2005, 11:40 PM
Julie's Avatar
Julie Julie is offline
 
Join Date: Mar 2005
Location: Oslo, Norway
Posts: 187
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Michelle
Thank you
What is funnier is the way I came up with it!
Some people (a very annoying competitor as well) that had only seen a little of my forum were saying that it has a very low level of average age which I knew was not true. So I put that in the forumhome and when they saw average age 29 they shut their mouths
Haha, wicked! Well, great ideas often come from simple things like that!
Reply With Quote
  #19  
Old 02-19-2006, 07:20 PM
El Barto El Barto is offline
 
Join Date: Oct 2005
Posts: 38
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

This didnt work in my forum.


Edit; it works fine, thanxs!
Reply With Quote
  #20  
Old 02-19-2006, 07:25 PM
Lea Verou Lea Verou is offline
 
Join Date: Jul 2005
Location: Greece
Posts: 1,856
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

What does it show?
Reply With Quote
  #21  
Old 02-19-2006, 07:45 PM
El Barto El Barto is offline
 
Join Date: Oct 2005
Posts: 38
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Michelle
What does it show?
I`m sorry, but I did something wrong.
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:28 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.04912 seconds
  • Memory Usage 2,308KB
  • 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_html
  • (5)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