Donation System Problem

Forum
Last Post
Threads / Messages

Zampher

Member
Member
Joined
May 19, 2011
Messages
2
Points
0
Mysidian Dollar
0
First of all I want to clarify that I am using the google translator, so I might not express correctly because I do not speak English (I'm Spanish)
The problem with the donation system is that if I enter an amount of money that I haven`t anyway reaches the user who I send it.
Example:
I have only $100, but I donated $10000 to X, the other user (X) will get $10000. Also happens with negative numbers.

I hope you understand the problem
Thank you very much and best regards

PS: Im using the version 1.2.2
 
Well experiencing some can resolve the problem that you can donate more than you have (I should clarify that I am not a programmer, not absolutely nothing about programming and what I did was rather a bit of "deduction"). Only a conditional solves that problem, but not that of the negative numbers.

Search:
Code:
if($_POST)

And add above
Code:
if($amount < $money){

Then Search:
Code:
else
{
	$article_title = $accden;
	$article_content = $reqlogin;
}

And replace with:
Code:
else
{
	$article_title = $accden;
	$article_content = "No puedes donar mas de lo que tienes";
}

}
 
Well its not that hard to fix, I make sure the bug does not exist in next release. All you have to do is to add a check point which prevent execution of the donation script if the user does not have enough money left.
 

Similar threads

Users who are viewing this thread

  • Forum Contains New Posts
  • Forum Contains No New Posts

Forum statistics

Threads
4,280
Messages
33,132
Members
1,603
Latest member
Monako
BETA

Latest Threads

Top