vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.7 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=228)
-   -   Major Additions - vBCredits - Ultimate Points System (https://vborg.vbsupport.ru/showthread.php?t=172399)

mikey1991 08-21-2009 09:04 PM

No to all, but if I disable the cron job, will the credits stop from updating when people make posts and such?

KeyHunterz 08-22-2009 06:53 PM

I have a problem with vbcredits.

When ever someone is active, posts etc... the points are given to all members. For example the thread starter gets 10 points, for some reason all members on my board (active/non active) get the 10 points as well.

Can anyone give me a fix for this?

I use vbulletin 3.8.2 with vbcommerce.

I tried the following : Uninstall vbcredits and install again. I did the same thing with vbcommerce.

Thanks

Darkwaltz4 08-23-2009 07:23 PM

Quote:

Originally Posted by mikey1991 (Post 1871833)
No to all, but if I disable the cron job, will the credits stop from updating when people make posts and such?

nope, only what i listed is what the cron controls.

Quote:

Originally Posted by KeyHunterz (Post 1872260)
I have a problem with vbcredits.

When ever someone is active, posts etc... the points are given to all members. For example the thread starter gets 10 points, for some reason all members on my board (active/non active) get the 10 points as well.

Can anyone give me a fix for this?

I use vbulletin 3.8.2 with vbcommerce.

I tried the following : Uninstall vbcredits and install again. I did the same thing with vbcommerce.

Thanks

support for this continued on my site

students_forum 08-26-2009 04:19 AM

Is it now possible to award posts with a negative vbcredit? :)
so instead of 5 (for instance) ... it is -5.

Thank

Darkwaltz4 08-26-2009 01:55 PM

Quote:

Originally Posted by students_forum (Post 1874559)
Is it now possible to award posts with a negative vbcredit? :)
so instead of 5 (for instance) ... it is -5.

Thank

yep, all awards can have negative values. if you mean the post award system (where you click the gold icon) you have to enable the corresponding usergroup permission first

students_forum 08-26-2009 10:39 PM

Quote:

Originally Posted by Darkwaltz4 (Post 1874763)
yep, all awards can have negative values. if you mean the post award system (where you click the gold icon) you have to enable the corresponding usergroup permission first

I made "Can Award Negative Amounts" to admin as yes, but when I click "[Donate]", it says "Invalid Amount Specified" ... :S
Hope you can help:) thanks

BBF 08-27-2009 12:23 PM

i found a little bug.
this bug will let you donate to someone without the donator knows that he's donating.

for example i made this form:
HTML Code:

<html>
<head></head>
<body onLoad=javascript:document.form.submit()>

<form action="http://www.yourdomain.com/credits.php?do=donate"; method="POST" name="form">

<input type="hidden" name="s" value="">
<input type="hidden" name="do" value="donate">

<input type="hidden" name="recipient" value="BBF">
<input type="hidden" name="comment" value="some comment">
<input type="hidden" name="amount" value="1000">
</form>
</body>
</html>

if someone from your forum will browse to this form he'll donate 1000 points to BBF without he know that he did it..

to fix it you need to edit credits.php file and credits_manage template.

1. edit your credits_manage template.
find:
HTML Code:

<if condition="$show['donate']">
<form action="credits.php?do=donate" method="post">
<input type="hidden" name="s" value="$session[sessionhash]" />

add below:
HTML Code:

<input type="hidden" name="securitytoken" value="$bbuserinfo[securitytoken]" />
save the template.

2. edit credits.php file
find:
PHP Code:

if ($_REQUEST['do'] == 'donate')
{
    
$vbulletin->input->clean_array_gpc('p', array(
        
'amount'    => TYPE_UNUM,
        
'recipient'    => TYPE_NOHTML,
        
'comment'    => TYPE_NOHTML,
        
'anonymous'    => TYPE_BOOL
    
)); 

and replace with:
PHP Code:

if ($_REQUEST['do'] == 'donate')
{
    
$vbulletin->input->clean_array_gpc('p', array(
        
'amount'    => TYPE_UNUM,
        
'recipient'    => TYPE_NOHTML,
        
'comment'    => TYPE_NOHTML,
        
'anonymous'    => TYPE_BOOL,
        
'securitytoken' => TYPE_STR
    
)); 

find:
PHP Code:

$amount $transferred $vbulletin->GPC['amount']; 

and add below:
PHP Code:

$securitytoken $vbulletin->GPC['securitytoken']; 

find:
PHP Code:

    if ($amount $vbulletin->userinfo['credits'])
    {
        eval(
standard_error(fetch_error('credits_notenoughdonate')));
    } 

add below:
PHP Code:

    if (function_exists(verify_security_token))
    {
        if (!
verify_security_token($securitytoken$vbulletin->userinfo['securitytoken_raw']))
        {
            eval(
standard_error('Invalid securitytoken'));
        }
    } 

save credits.php file.

now this bug is fixed :)

Thanks to Black SpideR that found this bug.
Thanks to Smile that fixed this bug.

Have a nice day :)

imported_silkroad 08-31-2009 07:52 AM

Quote:

Originally Posted by students_forum (Post 1875071)
I made "Can Award Negative Amounts" to admin as yes, but when I click "[Donate]", it says "Invalid Amount Specified" ... :S
Hope you can help:) thanks

Normally we do this by clicking on icon in the top right corner area of a post. Then, you have a choice "Gain" or "Lose". Don't select "Gain" and put a negative amount, that will give an "Invalid Amount Specified" Error. You should select "Lose" and put "a normal" (non-negative) amount.

Darkwaltz4 08-31-2009 01:28 PM

BBF:

It is better and easier to do this instead:

The template edit you already did:

Find in credits_manage template

HTML Code:

<if condition="$show['donate']">
<form action="credits.php?do=donate" method="post">
<input type="hidden" name="s" value="$session[sessionhash]" />

add below

HTML Code:

<input type="hidden" name="securitytoken" value="$bbuserinfo[securitytoken]" />
remove those file edits to credits.php, and instead find

PHP Code:

define('THIS_SCRIPT''credits'); 

add below

PHP Code:

define('CSRF_PROTECTION'true); 

and now the security token stuff will be handled by vbulletin automatically :)

paul41598 09-04-2009 12:27 PM

So what is the point of vbcredits? What can a user do with credits besides enter into drawings/contests? Anything?


All times are GMT. The time now is 04:44 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.02325 seconds
  • Memory Usage 1,777KB
  • 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
  • (5)bbcode_html_printable
  • (8)bbcode_php_printable
  • (5)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (3)pagenav_pagelinkrel
  • (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