![]() |
Members who have registered today
I was going to add this to my existing vbindex stats mod but it's a little too different so I will post it up as a new one, this has been requested a few times in the short time I have been here.
Update, corrected: Originally had forumindex.php when it should be index.php What it does: Adds a Registered Today (how many users in the last 24 hours) to the statistics on the forum index. Modifications: 1 Template 1 File 1 Phrase Add a phrase: Global Varname: reged_today Text: Registered Today In index.php find: PHP Code:
PHP Code:
Code:
<div>$vbphrase[threads]: $totalthreads, $vbphrase[posts]: $totalposts, $vbphrase[members]: $numbermembers</div> Code:
<div>$vbphrase[reged_today]: $newusers[count], $vbphrase[threads]: $totalthreads, $vbphrase[posts]: $totalposts, $vbphrase[members]: $numbermembers</div> That's it, I am supporting this please click install if you find it useful :) |
Very nice Hack! Big Thx!
|
Very nice! It worked right away for me.
For most people it'll be forum/index.php as the file to edit, not forumindex.php |
Quote:
|
Just Installed hack right now, www.socomjunky.com/forum very nice edition
|
Also displaying the names of the users who have registered would be cool :)
|
Just adding thanks!
|
just adding. thanks ericgtr!
|
Excelent work! Tnx!
|
Thanks.
|
exactly what i was looking for...! thanks
|
Is it possible to have it reset at midnight? so it shows the users registered that day rather then the last 24 hours...
|
Midnight for who? The server, you, or a member living in another timezone?
|
|
Quote:
|
Quote:
Thank You |
Edit: oops wrong query.
|
Quote:
This should work ; PHP Code:
|
I dont think that works as i know get a blank space where the number should be
http://www.majorfm.com/forum/ |
Does this count the registrations in the last 24 hours or since midnight for each user?
|
Thats what we are tryin to do now, the original hack does the last 24 hours, we are tryin to make it so it counts from midnight.
|
Paul's code in post 18 will do that. ;)
|
Yep, you are right Boofoo it works. Thanks Paul! :) and sorry for posting the wrong query up there guys I have to learn to label my code better in my index.php.
|
ok it works for you guys, im gettin a blank spot for some reason... i assume this will work when my forum passes midnight maybe..
|
You should still get a value of zero, I just registered and it still doesn't show. Try pasting it Paul's code above exactly if you haven't already I just tested on my site and it works.
|
i pasted that exactly replacing your original code... strange...
The segment in my index.php looks like this Code:
{ |
Any idea? i still get a blank spot..
|
Quote:
The two to change are hilighted below (on the WHERE line) ; Code:
{ Code:
WHERE joindate >= ' .$cutoff. ' |
I did this, still a blank... :-(
|
Hmm, I'm not sure how I've ended up supporting someone elses hack ;) - but yes, I can see the problem.
In the code I posted, change PHP Code:
PHP Code:
The reason is that the line changed in the FORUMHOME template is using the array value, not the subsequently created $newmembers variable; Code:
<div>$vbphrase[reged_today]: $newusers[count], $vbphrase[threads]: $totalthreads, $vbphrase[posts]: $totalposts, $vbphrase[members]: $numbermembers</div> |
Quote:
|
mine doesnt reset every 24hours
it adds on and on over the days and 2day it went from 28 register to 25 on its own please help |
Quote:
|
why has it been changed
|
Someone requested it start at midinight instead of the last 24 hours (sorry I mis-stated this in my last post) and that's why there is code in a bunch of posts here. But, if you install the modification the way it is in the first post, it will give you the last 24.
|
so what codes do i need? please state it for my host to read and correct the errors
|
The code you need is in the very first post of this thread (or at the top of each page)
|
thanx
|
Very cool! Very easy install and it works!
Thanks! |
i will show u the code.host says it same
|
All times are GMT. The time now is 06:35 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|