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)

Darkwaltz4 07-13-2009 07:52 PM

Quote:

Originally Posted by lafsunlmtd (Post 1845271)
hmmm.... it won't install on my master/slave server environ as is. it keeps trying to write to my slaves. I will try some other stuff and let you know if anything works.

do you have problems with other hacks or vbulletin not obeying this setting?

Quote:

Originally Posted by Saviour (Post 1845300)
Not sure if this has been covered before...too many posts to search.

Anyway...

When purchasing raffle tickets, I noticed that you will receive an error if you hit the Enter key instead of clicking on Purchase. It causes a database error with the below message:

Code:

Database error in vBulletin 3.8.3:
 
Invalid SQL:
SELECT * FROM vb_credits_lottery WHERE lotteryid =;
 
MySQL Error : You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1
Error Number : 1064
Request Date : Wednesday, July 8th 2009 @ 02:43:33 PM
Error Date : Wednesday, July 8th 2009 @ 02:43:34 PM
Script : http://xxxxxxxx.com/forums/credits.php?do=lottery
Referrer : http://xxxxxxxx.com/forums/credits.php?do=manage
IP Address : [removed]
Username : xxxxxx
Classname : vB_Database
MySQL Version : 5.0.67-log

Is this a bug? Is there a fix?

continued at support ticket

Quote:

Originally Posted by bluecamosis (Post 1847406)
Hi, I have a question about this hack. I've successfully installed it on my forums and it's working perfectly fine. But I have a query.

Is there a way to calculate the total amount of credits for a particular user group? I have 4 different "teams" in my forum, and I'm thinking of displaying the total amount of credits each group has accumulated, but I'm not sure how to do that. Help will be greatly appreciated thanks! =)

this isnt implemented by vbcredits no, but if you were making something custom you can query the user table based on usergroupid for a sum of the credits column

imported_silkroad 07-13-2009 08:06 PM

FWIW: We don't get this dB error when someone purchases a lottery ticket by hitting the "Enter Key" versus the "Purchase Button". I just tried it and it works fine.

bluecamosis 07-14-2009 03:08 PM

ah ok, i think i know what you're saying, but i've never done such coding before. if there's a site or a tutorial on writing queries somewhere? i dont mind trying to write the code... better learn it now or never right, lol, yeah well. whatever help i can get is greatly appreciated.

(oh and i'm actually intending to show the accumulated sums on forumhome, i hope this query thing will work!!)

pandoros 07-17-2009 02:08 AM

Im confused, on my loan box it says

Quote:

Amount must be between 200,000 and 1,000 Credits, and may be moderated. Minimum payments of 3.0% need to be paid back every 30 days to avoid late fees. Interest on outstanding balances is 19.5%. You may set up automatic payment plans. Your credibility rating may impact your interest rates or spending abilities.
now i dont know math well, but 1000 is smaller then 200,000.

How do I change the word credit, i went in global, but dont find it.
also what are "add-ons" for this addon?

Thanks

Farman 07-18-2009 04:29 AM

nice mod, I'll give it a try

motorola 07-18-2009 09:15 AM

I need to edit the files in the instalation.txt file?

50calray 07-18-2009 01:18 PM

Hello,

My name is Ray and I have recently installed vBcredits. I'm some what dumb when it comes to setting it up. I'm trying to figure out how to run a simple awards promotion based on points given for posting, starting threads, and referrals. I don't want to allow donations either. Do I simply set this up in "Manage Usergroup Awards" or do I need to change settings else were on the program?

Also, it say I can choose multiple groups in "Manage Usergroup Awards" but not sure how to choose multiples?

Thanks, and sorry for the noob question.

Ray

Darkwaltz4 07-18-2009 03:34 PM

Quote:

Originally Posted by imported_silkroad (Post 1848285)
FWIW: We don't get this dB error when someone purchases a lottery ticket by hitting the "Enter Key" versus the "Purchase Button". I just tried it and it works fine.

ive been getting secondhand reports of this error for a long time and have never been able to reproduce it. this latest one went nowhere fast as well :(

Quote:

Originally Posted by bluecamosis (Post 1848646)
ah ok, i think i know what you're saying, but i've never done such coding before. if there's a site or a tutorial on writing queries somewhere? i dont mind trying to write the code... better learn it now or never right, lol, yeah well. whatever help i can get is greatly appreciated.

(oh and i'm actually intending to show the accumulated sums on forumhome, i hope this query thing will work!!)

it would probably be a small job you would have to pay to make custom. the query part is pretty simple (stuff like: SELECT SUM(credits) FROM user WHERE usergroupid = X) but the actual arranging nicely on your homepage with templates and such is more in depth.

Quote:

Originally Posted by pandoros (Post 1850297)
Im confused, on my loan box it says

now i dont know math well, but 1000 is smaller then 200,000.

How do I change the word credit, i went in global, but dont find it.
also what are "add-ons" for this addon?

Thanks

your usergroup loan limit is 1000 but your global loan minimum is 200k - fix one or the other to make a valid range otherwise any attempt to get a loan will fail.

In the very first global setting for vbcredits, look in the description and theres a direct link to it. (the setting to enable vbcredits)

Some addons are listed here: http://www.vbcredits.com/projects/vbcredits/ along the left sidebar. However theres plenty of other addons that have variable settings to configure to use with vbcredits, plus third party addons that may be using vbcredits but didnt have to notify me

Quote:

Originally Posted by motorola (Post 1851041)
I need to edit the files in the instalation.txt file?

The templates it lists in the second half of the file.

Quote:

Originally Posted by 50calray (Post 1851113)
Hello,

My name is Ray and I have recently installed vBcredits. I'm some what dumb when it comes to setting it up. I'm trying to figure out how to run a simple awards promotion based on points given for posting, starting threads, and referrals. I don't want to allow donations either. Do I simply set this up in "Manage Usergroup Awards" or do I need to change settings else were on the program?

Also, it say I can choose multiple groups in "Manage Usergroup Awards" but not sure how to choose multiples?


Thanks, and sorry for the noob question.

Ray

You can use that link yes, to choose multiple groups from that list hold down ctrl while you click additional groups.

BlueChipEarth 07-18-2009 03:57 PM

This is awesome! Thanks!

motorola 07-18-2009 07:05 PM

And what I should do with these,, The templates it lists in the second half of the file.'' ?

Darkwaltz4 07-21-2009 04:09 PM

Quote:

Originally Posted by motorola (Post 1851283)
And what I should do with these,, The templates it lists in the second half of the file.'' ?

step three of the instructions explains what to do with them

Chelf12 07-21-2009 04:35 PM

Thanks for this. Love it. Also, one question. Although off-topic, how is work on vBCustomizer coming along?

Charles_1 07-21-2009 06:43 PM

Quote:

Originally Posted by Darkwaltz4 (Post 1818976)
if that hack is replacing the default vbulletin system internally, then they need to include the vbulletin hooks so that my system (and others that might be integrated there) can run their regular code there. otherwise if they are leaving it out, vbcredits doesnt execute there. there isnt much i can do at that point, have you shown this issue to that author?

Thanks for answer, but that author was last online on 10 Jul 2008 :-(. Could you please look at its hack to modify it in the way you mentioned? It is only one xml file with code 3 pages long - a piece of cake for you ;-).

Darkwaltz4 07-21-2009 08:15 PM

Quote:

Originally Posted by Chelf12 (Post 1853001)
Thanks for this. Love it. Also, one question. Although off-topic, how is work on vBCustomizer coming along?

i havent been able to get back to it as quickly as i wanted, but news on it wont be posted here :D

Quote:

Originally Posted by Charles_1 (Post 1853085)
Thanks for answer, but that author was last online on 10 Jul 2008 :-(. Could you please look at its hack to modify it in the way you mentioned? It is only one xml file with code 3 pages long - a piece of cake for you ;-).

this should do the trick: go into vb admin panel, Plugins & Products tab and the Plugin Manager link. Find the vBCredits - Earn / Lose Granted / Received Reputation plugin and edit it. Change Execution Order to 2 and save it. See if that fixes it.

Charles_1 07-21-2009 10:53 PM

Quote:

Originally Posted by Darkwaltz4 (Post 1853145)
this should do the trick: go into vb admin panel, Plugins & Products tab and the Plugin Manager link. Find the vBCredits - Earn / Lose Granted / Received Reputation plugin and edit it. Change Execution Order to 2 and save it. See if that fixes it.

I did it but it has no effect, credits are still not receiving for reputation. If I disable plugin "Alter Reputation" (which has the same hook location "reputation_add_process" as plugin "vBCredits - Earn / Lose Granted / Received Reputation") from product "User Defined User Points", credits are receiving (but that hack is not working of course). Another idea please?

Chrisg20 07-26-2009 02:54 AM

how i get this to show postbit

Darkwaltz4 07-27-2009 01:30 PM

Quote:

Originally Posted by Charles_1 (Post 1853207)
I did it but it has no effect, credits are still not receiving for reputation. If I disable plugin "Alter Reputation" (which has the same hook location "reputation_add_process" as plugin "vBCredits - Earn / Lose Granted / Received Reputation") from product "User Defined User Points", credits are receiving (but that hack is not working of course). Another idea please?

wait, so where did "User Defined User Points" come from? Maybe you can describe the whole problem to me via PM, the story has been stretched out and hard to remember what you have said is going on so far :)

Quote:

Originally Posted by Chrisg20 (Post 1855483)
how i get this to show postbit

follow the install instructions and it should be there when you are done

edytwinky 07-30-2009 03:16 PM

I just installed this and tried to mass credit update people's vbcredits and got this error:

PHP Code:

WarningDivision by zero in [path]/admincp/credits_admin.php on line 1283
Processing


Where would this have taken place at?

Also where do I state how many credits someone gets for a post or their birthday?

Darkwaltz4 07-30-2009 07:05 PM

Quote:

Originally Posted by edytwinky (Post 1858564)
I just installed this and tried to mass credit update people's vbcredits and got this error:

PHP Code:

WarningDivision by zero in [path]/admincp/credits_admin.php on line 1283
Processing


Where would this have taken place at?

Also where do I state how many credits someone gets for a post or their birthday?

for the error: set to 1 your global setting for number of valid referrals per referral point - thats not actually the award they get for a referral

THAT is set in the usergroup settings, which is also where the other two settings you are looking for are.

edytwinky 08-02-2009 03:56 AM

Thank you. That worked perfectly.

Charles_1 08-02-2009 12:43 PM

Quote:

Originally Posted by Darkwaltz4 (Post 1856501)
wait, so where did "User Defined User Points" come from? Maybe you can describe the whole problem to me via PM, the story has been stretched out and hard to remember what you have said is going on so far :)

:-) OK, I will send you PM today, thanks.

edytwinky 08-03-2009 06:03 AM

How do I change the Richest Users page to eliminate the Contact Column? Or at least remove the SendPM and E-mail images?

Darkwaltz4 08-03-2009 06:12 AM

go ahead and modify the credits_manage and credits_toprow templates to remove those table columns

WordKeeper 08-09-2009 03:48 AM

Thanks for the mod! and vBcommerce is awesome too.

bada_bing 08-09-2009 02:49 PM

Just curious to how others are using this hack? What is the main purpose on your site. I am looking for a hack that I can use to reward members for top thread, top posted, top activity,etc would this work to should I be looking at something else?

Suliman Mashat 08-16-2009 02:37 PM

Thankes

mikey1991 08-18-2009 05:08 PM

Are the template edits compulsory? Say I just wanted to use the system and didn't want members to know it was installed, and use it as a tracking thing for points, the template edits aren't needed, right?

Darkwaltz4 08-18-2009 09:11 PM

Quote:

Originally Posted by mikey1991 (Post 1869945)
Are the template edits compulsory? Say I just wanted to use the system and didn't want members to know it was installed, and use it as a tracking thing for points, the template edits aren't needed, right?

if you want anything displayed the edits have to be made. however, there are visibility settings for turning stuff off for certain groups so you wont have to always go to profiles and stuff if you are a staff member

mikey1991 08-21-2009 12:05 AM

Thanks for the reply, it turned out fine with no edits, so that's cool :)

I now have the problem where all the credits suddenly reset to zero after a period of around 24hrs... Do you know how to stop this? Great mod btw :)

Darkwaltz4 08-21-2009 03:03 PM

Quote:

Originally Posted by mikey1991 (Post 1871324)
Thanks for the reply, it turned out fine with no edits, so that's cool :)

I now have the problem where all the credits suddenly reset to zero after a period of around 24hrs... Do you know how to stop this? Great mod btw :)

hm, seems that a rare couple people have the cron reset their credits. seems you are one of them. are you using the birthday, activity, or paycheck awards? do you use the bank or lottery? if no to all of them, you can disable the credits daily scheduled task.

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 12:21 AM.

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.04365 seconds
  • Memory Usage 1,893KB
  • 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
  • (1)bbcode_code_printable
  • (5)bbcode_html_printable
  • (10)bbcode_php_printable
  • (25)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)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