vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   vBa CMPS: users registered today (https://vborg.vbsupport.ru/showthread.php?t=72885)

ericgtr 12-13-2004 10:00 PM

vBa CMPS: users registered today
 
This will add a "Registered Today" (actually in the last 24 hours) to your Stats box.

Add a phrase:
Global
Varname: reged_today
Text: Registered Today

In the adv_portal_stats template:

Find:
Code:

$vbphrase[top_poster]: <a href="$vboptions[bburl]/member.php?$session[sessionurl]u=$topposter[userid]">$topposter[username]</a> ($topposter[posts])<br />
Below add:
Code:

$vbphrase[reged_today]: ($newusers[count])<br />
Open modules/stats.php

Find:
Code:

$newuserid = $userstats['newuserid'];
Add below:
Code:

$newusers = $DB_site->query_first('
SELECT COUNT(*) AS count
    FROM ' . TABLE_PREFIX . 'user
    WHERE joindate >= "' . strtotime("-1day") . '"
');
$newmembers = number_format($newusers['count']);

Thanks a lot to KW802 for help with the query.

Lethal 12-14-2004 02:58 PM

nice, thanks

Polo 12-14-2004 04:03 PM

cool ;)

paulmjno 12-14-2004 04:56 PM

Nice. :) Will install soon.

Edit: Installed. Works perfectly. :D Thank you.

ericgtr 12-14-2004 09:13 PM

Quote:

Originally Posted by paulmjno
Nice. :) Will install soon.

Edit: Installed. Works perfectly. :D Thank you.

Your welcome, glad to see it getting some use :)

NYI Fan 12-15-2004 12:58 PM

Nice touch! Thanks :up:

shadiguy1 12-15-2004 01:44 PM

some reason itr isnt working for me.

ericgtr 12-15-2004 02:00 PM

Quote:

Originally Posted by shadiguy1
some reason itr isnt working for me.

Does it give an error or is it blank?

shadiguy1 12-15-2004 04:01 PM

its blank not showing up

ericgtr 12-15-2004 04:40 PM

Okay, double check your stats.php and make sure you posted all of the code exactly where I mention or start over from scratch, as long as that's there it should show up. Also, make sure your DB prefix is the same.


All times are GMT. The time now is 03:20 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.01034 seconds
  • Memory Usage 1,728KB
  • 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
  • (4)bbcode_code_printable
  • (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