Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.5 > vBulletin 3.5 Add-ons

Reply
 
Thread Tools
Visitor Totals Last 24hrs Details »»
Visitor Totals Last 24hrs
Version: 1.02, by tcs tcs is offline
Developer Last Online: Apr 2014 Show Printable Version Email this Page

Version: 3.5.1 Rating:
Released: 11-12-2005 Last Update: 11-15-2005 Installs: 34
Uses Plugins Template Edits
Code Changes  
No support by the author.

ported for 3.5.x.

It's a cool hack if you like to look at your total hits in a 24hr day from both members and guests.

1 PHP Modification to includes/cleanup.php
1 Template Mod. to Forumhome
1 Product Pluggin

Instructions and XML are in the zip.

I will support this hack but should be much trouble with it. Been running it since vB 2.2 I think.

When you first install this hack it will only track from the time the last sessions cleanup was completed. After a sessions cleanup it will start over or reset to 1hr again. Then track the hours in increments for 24hrs. Then clean out the sessions table and start over again. Sessions cleanups should normally occur at midnight.

This hack works if you remove the old code in the cleanup.php and replace it with the new information in the readme.

For information cleanout2.php dose not run hourly like implied in the cron tab. It is set for 5 min after midnight. Jelsoft set it that way and not sure why it is titled a hourly cleanup in the scheduled task. In any event it is needed to reset the script for the next day.

Good luck and I will do my best to answer any questions.

Thanks to Paul M. for pointing out a bug I kept overlooking.

Show Your Support

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

Comments
  #32  
Old 11-14-2005, 11:22 PM
tcs's Avatar
tcs tcs is offline
 
Join Date: Jun 2002
Posts: 130
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by amykhar
Typo in the install file.

Code:
$vbulletin->db->query_write("
	DELETE FROM " . TABLE_PREFIX . "session
	WHERE lastactivity < " . intval((TIMENOW - 86400]) . "
        ### Delete stale sessions ###
Should be
Code:
$vbulletin->db->query_write("
	DELETE FROM " . TABLE_PREFIX . "session
	WHERE lastactivity < " . intval((TIMENOW - 86400)) . "
        ### Delete stale sessions ###
Thanks, There was a typo on my part. If you have the final spider code input let me know and I will add it and your credits to the install.

Zip file is updated.
Reply With Quote
  #33  
Old 11-14-2005, 11:54 PM
amykhar's Avatar
amykhar amykhar is offline
 
Join Date: Oct 2001
Location: PA
Posts: 4,438
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

With this code running, I am having the same error others are reporting. The results are for one hour, even though it's been running for several. I am at work right now and won't be able to analyze the code till later. If I figure out what's amiss, I'll let y'all know.
Reply With Quote
  #34  
Old 11-15-2005, 12:15 AM
JTyson JTyson is offline
 
Join Date: Apr 2005
Location: This Thread
Posts: 140
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ive said it before but cleanup2.php also has the same delete statement in it that needs to be modified.
Reply With Quote
  #35  
Old 11-15-2005, 12:16 AM
caliman's Avatar
caliman caliman is offline
 
Join Date: Jan 2005
Location: California
Posts: 256
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by JTyson
Ive said it before but cleanup2.php also has the same delete statement in it that needs to be modified.
So is it working for you JTyson?
Reply With Quote
  #36  
Old 11-15-2005, 12:41 AM
Paul M's Avatar
Paul M Paul M is offline
 
Join Date: Sep 2004
Location: Nottingham, UK
Posts: 23,748
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by tcs
Thanks, There was a typo on my part. If you have the final spider code input let me know and I will add it and your credits to the install.

Zip file is updated.
This bit
Code:
intval((TIMENOW - 86400))
only needs one bracket each side.
Reply With Quote
  #37  
Old 11-15-2005, 01:26 AM
caliman's Avatar
caliman caliman is offline
 
Join Date: Jan 2005
Location: California
Posts: 256
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

So does this thing work for you Paul? Anybody? Seems like the behavior I described earlier is still happening for a few people here.
Reply With Quote
  #38  
Old 11-15-2005, 01:36 AM
tcs's Avatar
tcs tcs is offline
 
Join Date: Jun 2002
Posts: 130
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Paul M
This bit
Code:
intval((TIMENOW - 86400))
only needs one bracket each side.

Thanks, Fixed it in the zip file. Also added to change cleanup2.php. I can concede that this might need to be changed even though it works fine on my site without this additional change.

For those that don't wish to download the zip again this is the code. If you don't wish to change it the (( is fine too.

Code:
$vbulletin->db->query_write("
	DELETE FROM " . TABLE_PREFIX . "session
	WHERE lastactivity < " . intval(TIMENOW - 86400) . "
        ### Delete stale sessions ###
Chuck
Reply With Quote
  #39  
Old 11-15-2005, 02:30 AM
amykhar's Avatar
amykhar amykhar is offline
 
Join Date: Oct 2001
Location: PA
Posts: 4,438
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'm not so sure about the quality of the data. Right now, it's saying I've had 59 members on in the last 3 hours - but my Total Members that have visited the site today says only 46 have logged in today.

Amy
Reply With Quote
  #40  
Old 11-15-2005, 10:33 AM
tcs's Avatar
tcs tcs is offline
 
Join Date: Jun 2002
Posts: 130
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by amykhar
I'm not so sure about the quality of the data. Right now, it's saying I've had 59 members on in the last 3 hours - but my Total Members that have visited the site today says only 46 have logged in today.

Amy
No it is doing what it is meant to do. It is a Hit counter for a day. Counts all the visitors to your site. If you visit your site twice then that is 2 registered members hit's.

Now it has a error, it didn't clean out at midnight last night and I need to figure out why, I am pulling the hack till I get it back to the way I intended it to work.
Reply With Quote
  #41  
Old 11-15-2005, 03:56 PM
COBRAws's Avatar
COBRAws COBRAws is offline
 
Join Date: Oct 2002
Location: Buenos Aires
Posts: 864
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by amykhar
With this code running, I am having the same error others are reporting. The results are for one hour, even though it's been running for several. I am at work right now and won't be able to analyze the code till later. If I figure out what's amiss, I'll let y'all know.
same here, more than 36hrs running and only see the last hour stats.

Will wait till tcs works on the redo
Reply With Quote
Reply

Thread Tools

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 01:45 AM.


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.05425 seconds
  • Memory Usage 2,311KB
  • Queries Executed 25 (?)
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
  • (5)bbcode_code
  • (6)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
  • (4)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