vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Requests/Questions (Unpaid) (https://vborg.vbsupport.ru/forumdisplay.php?f=112)
-   -   Hack Help (https://vborg.vbsupport.ru/showthread.php?t=49145)

BigJohnson 02-20-2003 11:41 AM

Nope that did not work neither. Same thing. Just showing the average for the quads.

BigJohnson 02-20-2003 11:43 AM

ya with the last bit u posted i just get average is 0. ;)

Sebastian 02-20-2003 11:48 AM

lol. Okay try this... I didn't realise the adding was above the } else {

PHP Code:

$qbtime = (time() - $userinfo[joindate]) / 2592000// Days Joined
  
if ($qbtime 1) { // User has been a member for less than one day.
    
$qbpermonth "$userinfo[quads]";
  } else {
    
$qbpermonth += $userinfo[quads] + $userinfo[bikes];
    
$qbpermonth sprintf("%.2f",($qbpermonth $qbtime));
  } 


Sebastian 02-20-2003 11:52 AM

also ... what is the } else { there for? either way all you are doing is getting average right?

I see you are getting info when the user joined, but either way new user or not you want a total caculated?

BigJohnson 02-20-2003 11:52 AM

nope still not working. Just showing the average for just the quads. hhmm. Is there any other way of adding the 2?

BigJohnson 02-20-2003 11:54 AM

well i have the else because I when someone has 0 posts for quads the average is not 0 I think. I don't know. It doesnt hurt to have ti anyway so that cannot be the problem.

Sebastian 02-20-2003 11:57 AM

i am usually good with math ;)
if this doesn't work then maybe Xenon can give it a crack.

PHP Code:

$qbpermonth += $userinfo[quads] + $userinfo[bikes];
$qbtime = (time() - $userinfo[joindate]) / 2592000// Days Joined
  
if ($qbtime 1) { // User has been a member for less than one day.
    
$qbpermonth $qbpermonth;
  } else {
    
$qbpermonth sprintf("%.2f",($qbpermonth $qbtime));
  } 


BigJohnson 02-20-2003 11:59 AM

Ya i did that already. You told me to do that before but then u edited ur post. I saw both of the ways u did it hehe. Ya that doesn't neither. Hehe. I guess we can wait for Xenon then hehe. Thanks so much for trying though man. Its the thought that counts.


All times are GMT. The time now is 08:22 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.01294 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_php_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (8)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