vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Postcount problem (https://vborg.vbsupport.ru/showthread.php?t=67436)

SnowBot 07-21-2004 04:48 AM

Postcount problem
 
Hi guys, well i have just noticed a strange problem regarding my post counts and as i have just noticed it i have no idea when it went wrong, i mean after what hack i installed.

OK basically the prob is this

OK in the postbit it says i have

Posts: 1,740

This is correct BUT in my profile it says

Total Posts: 1 (4.93 posts per day)

Another admin has 2000+ posts and in her profile it says 2 but in postbit it says the correct 2000+ posts. Now a member with less than 1000 posts, say 30 posts for example it shows correct in both postbit and profile page. Any ideas what can be wrong and how to fix this? It seems if you have more than 1000 posts it messes up.

The guys over at vb.com will not help as its a hacked board, thats fine but i need help guys. If someone can suggest things for me to look for or anything please help :)

Snowy

Andreas 07-21-2004 07:07 AM

Strange :)
Did you modify member.php or MEMBERINFO?

If so check both carefully.

Xenon 07-21-2004 02:18 PM

sounds like a incorrect hack for me as well.

numberformating problem i'd say.

be sure you have that line, just be called once:
PHP Code:

    $userinfo['posts'] = vb_number_format($userinfo['posts']); 

and afterwards make sure, that below that line, isn't something like:
PHP Code:

$userinfo['posts'] = intval($userinfo['posts']); 

at least that would result in exactly the problem you explained.

SnowBot 07-21-2004 02:43 PM

Quote:

Originally Posted by Xenon
sounds like a incorrect hack for me as well.

numberformating problem i'd say.

be sure you have that line, just be called once:
PHP Code:

    $userinfo['posts'] = vb_number_format($userinfo['posts']); 

and afterwards make sure, that below that line, isn't something like:
PHP Code:

$userinfo['posts'] = intval($userinfo['posts']); 

at least that would result in exactly the problem you explained.

aaahhh I have that line twice, but which to remove?

member.php
PHP Code:

 // User has been a member for less than one day.
$userinfo['posts'] = vb_number_format($userinfo['posts']);
$postsperday $userinfo['posts'];
}
else
{
$postsperday vb_number_format($userinfo['posts'] / $jointime2);
$userinfo['posts'] = vb_number_format($userinfo['posts']);
}
// THREADS STARTED AND THREADS PER DAY 


CarCdr 07-21-2004 03:14 PM

Xenon nailed it. Line 392:
Code:

$userinfo['posts'] = intval ( $userinfo['posts'] ) ;

SnowBot 07-21-2004 03:48 PM

Quote:

Originally Posted by CarCdr
Xenon nailed it. Line 392:
Code:

$userinfo['posts'] = intval ( $userinfo['posts'] ) ;

so i just remove that line?

SnowBot 07-21-2004 03:50 PM

yep that worked :) Guys you are all pure stars. This place is so helpful and when you are registered as blind as i am all the help you guys give is much more appreciated :)

Xenon 07-21-2004 03:52 PM

You're welcome :)

But please don't post full vb files here next time, as this isn't allowed.

SnowBot 07-21-2004 03:54 PM

aahhh appologies, i didnt know but i do now :):)


All times are GMT. The time now is 03:54 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.00995 seconds
  • Memory Usage 1,740KB
  • 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_code_printable
  • (5)bbcode_php_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (9)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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete