vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   Total Members (Registrations) Hack (https://vborg.vbsupport.ru/showthread.php?t=54454)

Albasoul 06-18-2003 04:30 PM

This hack is not a good idea to install on your boards, especially busy ones, because any sql query that uses select count(*) degrades mysql performance by counting a large number of rows from the user table.

I like the idea, i just don't like to install this because I am sure it will kill performance.

Crinos 06-18-2003 04:42 PM

I regularly prune my member database every month for inactive members who 1.) have never made a post + 2.) have not visited the site in 3 months ... so I probably won't need this hack ... good idea tho, congrats ;)

Kaelon 06-18-2003 05:21 PM

Quote:

This hack is not a good idea to install on your boards, especially busy ones, because any sql query that uses select count(*) degrades mysql performance by counting a large number of rows from the user table.
Did you even look at the code? There are no added queries in this hack. Specifically, it uses a query already needed by forumhome (the one that generates the newuserid) and simply formats that number using an in-the-box routine.

Our forum has hundreds of simultaneous users, and we have experienced no increase in server load.

Kaelon

N9ne 06-18-2003 06:11 PM

Hehe, I did this in my 4th hack I think, it's really amazing that no one did do it separately. In my hack I did the same for threads and posts (shows posts posted total and threads posted total) and I've done the same for vB3.

Nice work Kaelon, hopefully people will use it, because it should technically be standard vBulletin, to show members total, registered, but that's just my opinion.

Dean C 06-18-2003 07:59 PM

I'm still a little confused as to what this does *confused*? :)

- miSt

S.Shady 06-18-2003 09:36 PM

Quote:

Today at 05:59 PM Mist said this in Post #15
I'm still a little confused as to what this does *confused*? :)

- miSt

i wasl also confused but then i noticed if you put a comma right after (active) it will all make sence


ok if your forum has had a total of 1,287 members since you opend total.

and you prune 500 off because of inactivity

this hac will say

Current Active # of Members: 787
Total To date reg. members 1,287

Kaelon 06-19-2003 03:19 AM

S.Shady is correct; it essentially takes the $newuserid variable and runs it through the format_number routine, and displays it. This gives users an idea of how many accounts have ever been created on a forum (since $newuserid is sequential).

This, of course, means different things for different forums. For my forum, it represents the number of total members registered, but not pruned due to inactivity (since we regularly prune thousands of inactive accounts).

Kaelon

Floris 06-21-2003 03:30 PM

I don't want to spoil your fun, but ... why does this require source code hacking ?

The 'welcome to our latest member' .. his userid is the last one in the database, and therefor also the total amount you want to get right ? Just display that.

Total registrations, ever: $newuserid
Total active members: $numbermembers

csidlernet 06-21-2003 08:04 PM

You have a point: xiphoid, but I guess you still could call this a hack as it does involve file editing.

Floris 06-21-2003 10:03 PM

Then I will rephrase my point: It is an obsolete hack!

vBulletin's forumhome already lets you have this number, why stress the server to re-calculate it ?

Just modify the template and you are done. This way upgrading doesn't have to bother you. The variable is currently the same in vb3 too.


All times are GMT. The time now is 08:32 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01526 seconds
  • Memory Usage 1,733KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.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
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete