Go Back   vb.org Archive > vBulletin Modifications > Archive > Modification Graveyard
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Time Spent On Board Details »»
Time Spent On Board
Version: 1.00, by tnguy3n tnguy3n is offline
Developer Last Online: Sep 2010 Show Printable Version Email this Page

Category: End-User Options - Version: 3.6.4 Rating:
Released: 12-01-2006 Last Update: Never Installs: 84
 
No support by the author.

Total Time Spent On Board (for vB 3.6.x)
Author: tnguy3n
Live Demo: http://www.vbviet.org/forums/member.php?u=1

This hack displays total time that users spent on the board in postbit and member info page.

To show all time units including seconds, minutes, hours, etc, uncomment some line codes in "Total Spent Time On Board" plugin.

Query: 1
File mod: 1
Template mod: 1

######################################
INSTALLATION:

1. Import product-totaltime.xml in Product Manager
2. Modify file & make changes in templates as instructed in install.txt file

---------------------------
Upgrade from v.1.0 (for vB 3.5.x)?
Just simply select the overwrite option upon importing the product xml file.

Show Your Support

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

Comments
  #12  
Old 12-03-2006, 09:48 AM
lifesourcerec's Avatar
lifesourcerec lifesourcerec is offline
 
Join Date: Jan 2002
Posts: 429
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

This mod never liked me. It doesn't break down the time. Only gives a long number.
Reply With Quote
  #13  
Old 12-03-2006, 10:18 AM
LordDB LordDB is offline
 
Join Date: Aug 2006
Location: CoffeeFads.Co.Uk
Posts: 189
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

tnguy3n, great hack, but, your screenshot shows you as been on your forum for:

1 week, 3 days, 23 hours

why doesn't mine show such lengths of time, as I can't believe you've been connected online at your forum that duration of time.

It only shows mine as:

38 mins, 20 secs

Do enlighten us as to what I've done wrong, or how to adjust such info.

Thx n regards

Reply With Quote
  #14  
Old 12-03-2006, 02:16 PM
farukcan's Avatar
farukcan farukcan is offline
 
Join Date: Oct 2006
Posts: 27
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

tahanks...

Installed....
Reply With Quote
  #15  
Old 12-03-2006, 03:18 PM
Shazz's Avatar
Shazz Shazz is offline
 
Join Date: Jun 2006
Location: Utah
Posts: 4,758
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by daPLAYBOY View Post
tnguy3n, great hack, but, your screenshot shows you as been on your forum for:

1 week, 3 days, 23 hours

why doesn't mine show such lengths of time, as I can't believe you've been connected online at your forum that duration of time.

It only shows mine as:

38 mins, 20 secs

Do enlighten us as to what I've done wrong, or how to adjust such info.

Thx n regards


I think you might have had the same problem as me
Reply With Quote
  #16  
Old 12-03-2006, 03:35 PM
aveon's Avatar
aveon aveon is offline
 
Join Date: May 2006
Posts: 410
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by lifesourcerec View Post
This mod never liked me. It doesn't break down the time. Only gives a long number.

same here how can we resolve this????
Reply With Quote
  #17  
Old 12-03-2006, 04:01 PM
JuGgOlOw22 JuGgOlOw22 is offline
 
Join Date: Aug 2006
Posts: 34
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

any one know how to fix this i cant get it back

Parse error: syntax error, unexpected '*' in /home/nexte3/public_html/includes/class_core.php on line 2892
Reply With Quote
  #18  
Old 12-03-2006, 04:09 PM
MrPHD's Avatar
MrPHD MrPHD is offline
 
Join Date: Feb 2006
Location: Portugal
Posts: 385
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

It seens you wrong edit the file, you can see ", 'lastvisit');

$this->userinfo['lastvisit'] = $this->userinfo['lastactivity'];
}
else
{

This is the line you tell an error, you can fix that unistall the hack and edit classcore.php again. Regards

Open includes/class_core.php, (1 change)

FIND:

// on this to be updated in real time.
$this->registry->db->shutdown_query("
UPDATE " . TABLE_PREFIX . "user
SET lastactivity = " . TIMENOW . "
WHERE userid = " . $this->userinfo['userid'] . "
", 'lastvisit');

REPLACE WITH:

// on this to be updated in real time.
/* $this->registry->db->shutdown_query("
UPDATE " . TABLE_PREFIX . "user
SET lastactivity = " . TIMENOW . "
WHERE userid = " . $this->userinfo['userid'] . "
", 'lastvisit');
*/

if(TIMENOW - $this->userinfo['lastactivity'] > $this->registry->options['cookietimeout'])
{
$newtime = '0';
}
else
{
$newtime = TIMENOW - $this->userinfo['lastactivity'];
}
$this->registry->db->shutdown_query("
UPDATE " . TABLE_PREFIX . "user
SET lastactivity = " . TIMENOW . ",
timeonboard = timeonboard + $newtime
WHERE userid = " . $this->userinfo['userid'] . "
", 'lastvisit');

if you don´t know use php well, i advice backup the original file allways, and you can backup renamed like class_core.phpold and put edited file and chmod 777.
Reply With Quote
  #19  
Old 12-03-2006, 06:41 PM
tnguy3n's Avatar
tnguy3n tnguy3n is offline
 
Join Date: May 2003
Location: U of I, Iowa
Posts: 846
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

that's the total time I've spent on my board, and my board has been open for 1 1/2 years now. Note that your total time counts only at the point your install this hack.
Reply With Quote
  #20  
Old 12-03-2006, 11:12 PM
lifesourcerec's Avatar
lifesourcerec lifesourcerec is offline
 
Join Date: Jan 2002
Posts: 429
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Got it working. Looks like it was conflicting with another code.
Reply With Quote
  #21  
Old 12-08-2006, 07:03 AM
underESTIMATED underESTIMATED is offline
 
Join Date: Feb 2005
Location: Akron, Oh
Posts: 43
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Fatal error: Cannot redeclare timeonboard() (previously declared in /home/ohiosci/public_html/forum/global.php(356) : eval()'d code:4) in /home/ohiosci/public_html/forum/member.php(825) : eval()'d code on line 4

Help!?


Happens when I click on a members name to see their profile, otherwise it's fine.

I missed this hack when I upgraded versions, nice to see that somewhere in all my previous coding it kept my times too! I pissed alot of people off. lol
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 11:36 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.06118 seconds
  • Memory Usage 2,306KB
  • 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
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (4)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