• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

People don't get points via paypal

axas

Well-Known Member
Joined
Feb 23, 2008
Messages
870
Reaction score
94
Hello. I've been setting up the paypal point donation script today, and encountered a problem. Everything works fine, the money my friend donated transfers to my bank account but the thing that points don't appear in his account.

I couldn't find any tutorial, so I tried fixing both files by myself. Here's what they look like right now. Only been trying to fix these 2 files.


Paypal.htm
PHP:
<b>Automatic PayPal Donation System.</b><br><br>
The donation costs 5 EUR (incl. VAT).<br>
After the donation you will receive <b>50 points + 30 bonus points (Tot. 80 points)</b> in your account automatically. <br>You will receive +30 bonus points for free because you donate with PayPal / Creditcard.<br><br>

<b>Here are the steps you need to make:</b> <br>
1. You need a valid creditcard <b>or</b> a PayPal account with a required balance [5 EUR]. <br>
2. Fill in your account number. <br>
3. Click on the donate button. <br>
4. Make a transaction on PayPal. <br>
5. After the transaction 80 points will be automatically added to your account. <br>
6. Go to Item shop and use your points <br> <br> <br> </b>



<form action="https://www.paypal.com/cgi-bin/webscr" method="post">
<input type="hidden" name="cmd" value="_donations">
<input type="hidden" name="business" value="[email protected]">
<input type="hidden" name="lc" value="GB">
<input type="hidden" name="item_name" value="Donation">
<b>Account number:</b> <input type="text"  name="custom" value="">
<input type="hidden" name="item_number" value="1">
<input type="hidden" name="amount" value="5.0">
<input type="hidden" name="currency_code" value="EUR">
<input type="hidden" name="no_note" value="0">
<input type="hidden" name="no_shipping" value="0">
<input type="hidden" name="currency_code" value="EUR">
<input type="hidden" name="notify_url" value="http://78.56.106.28:7173/paypal/ipn/ipn.php">
<input type="hidden" name="return" value="http://78.56.106.28:7173/">
<input type="hidden" name="rm" value="0">
<input type="hidden" name="bn" value="PP-DonationsBF:btn_donateCC_LG_global.gif:NonHosted">
<input type="image" src="https://www.paypal.com/en_US/i/btn/btn_donate_LG.gif" border="0" name="submit" alt="PayPal - The safer, easier way to pay online.">
<img alt="" border="0" src="https://www.paypal.com/en_US/i/scr/pixel.gif" width="1" height="1">
</form>

Ipn.php
PHP:
<?  
$mysql_host = 'localhost'; //Leave at localhost  
$mysql_user = 'name'; //DB User  
$mysql_pass = 'password'; //DB Pass  
$mysql_db = 'dbname'; //DB Name  
$file = 'paypal.log'; //Paypal Log Name will be placed in the same location as your ipn.php file 

$custom = stripslashes(ucwords(strtolower(trim($_REQUEST['custom']))));  
$receiver_email = $_REQUEST['receiver_email'];  
$payment_status = $_REQUEST['payment_status'];  
$mc_gross = $_REQUEST['mc_gross'];  
$payer_email = $_REQUEST['payer_email']; 

$somecode = "'$custom' '$payer_email' '$mc_gross'"; 

// connect db  

$db = mysql_connect($mysql_host, $mysql_user, $mysql_pass);  
mysql_select_db($mysql_db, $db);  
if ($payment_status == "Completed" & $receiver_email == "[email protected]" & $mc_gross == "##.##") {  

$query = "SELECT premium_points FROM accounts WHERE accounts.name = '$custom'";  

$result = mysql_query($query);  

$prem = mysql_fetch_array($result);  

$points = $prem['premium_points'] + 80;  
// $points = mysql_query($prem)  
$qry2 = "UPDATE accounts SET premium_points = '$points' WHERE accounts.name = '$custom'";  
// Log Paypal Transaction 
$hak = fopen($file, "a"); 
fwrite($hak, $somecode); 
fclose($hak); 

$result2 = mysql_query($qry2);  
}  
else  
 {   
 echo("Error.");  
 }  
?>

Rep++ to anyone who helps me.
 
It works to give it manually via database, but automatic would be way better.
 
You guys changed the mysql password and DB name in ipn.php?? xD:
PHP:
<?  
$mysql_host = 'localhost'; //Leave at localhost  
$mysql_user = 'name'; //DB User  
$mysql_pass = 'password'; //DB Pass  
$mysql_db = 'dbname'; //DB Name  
$file = 'paypal.log'; //Paypal Log Name will be placed in the same location as your ipn.php file
 
you just need to edit
ipn.php
Code:
$mc_gross == "##.##"

in your case it will be:
Code:
$mc_gross == "5.0"

it was made by someone so people can't donate like 0.1 eur and receive points :p
 
you just need to edit
ipn.php
Code:
$mc_gross == "##.##"

in your case it will be:
Code:
$mc_gross == "5.0"

it was made by someone so people can't donate like 0.1 eur and receive points :p

hey man i tried that but it still didnt work.

PHP:
if ($payment_status == "Completed" & $receiver_email == "[email protected]" & $mc_gross == "10.00") {

do you have any other advice on what to test? i already configured the connection to the database and the server and the website.
 
Hello. I've been setting up the paypal point donation script today, and encountered a problem. Everything works fine, the money my friend donated transfers to my bank account but the thing that points don't appear in his account.

I couldn't find any tutorial, so I tried fixing both files by myself. Here's what they look like right now. Only been trying to fix these 2 files.


Paypal.htm
PHP:
<b>Automatic PayPal Donation System.</b><br><br>
The donation costs 5 EUR (incl. VAT).<br>
After the donation you will receive <b>50 points + 30 bonus points (Tot. 80 points)</b> in your account automatically. <br>You will receive +30 bonus points for free because you donate with PayPal / Creditcard.<br><br>

<b>Here are the steps you need to make:</b> <br>
1. You need a valid creditcard <b>or</b> a PayPal account with a required balance [5 EUR]. <br>
2. Fill in your account number. <br>
3. Click on the donate button. <br>
4. Make a transaction on PayPal. <br>
5. After the transaction 80 points will be automatically added to your account. <br>
6. Go to Item shop and use your points <br> <br> <br> </b>



<form action="https://www.paypal.com/cgi-bin/webscr" method="post">
<input type="hidden" name="cmd" value="_donations">
<input type="hidden" name="business" value="[email protected]">
<input type="hidden" name="lc" value="GB">
<input type="hidden" name="item_name" value="Donation">
<b>Account number:</b> <input type="text"  name="custom" value="">
<input type="hidden" name="item_number" value="1">
<input type="hidden" name="amount" value="5.0">
<input type="hidden" name="currency_code" value="EUR">
<input type="hidden" name="no_note" value="0">
<input type="hidden" name="no_shipping" value="0">
<input type="hidden" name="currency_code" value="EUR">
<input type="hidden" name="notify_url" value="http://78.56.106.28:7173/paypal/ipn/ipn.php">
<input type="hidden" name="return" value="http://78.56.106.28:7173/">
<input type="hidden" name="rm" value="0">
<input type="hidden" name="bn" value="PP-DonationsBF:btn_donateCC_LG_global.gif:NonHosted">
<input type="image" src="https://www.paypal.com/en_US/i/btn/btn_donate_LG.gif" border="0" name="submit" alt="PayPal - The safer, easier way to pay online.">
<img alt="" border="0" src="https://www.paypal.com/en_US/i/scr/pixel.gif" width="1" height="1">
</form>

Ipn.php
PHP:
<?  
$mysql_host = 'localhost'; //Leave at localhost  
$mysql_user = 'name'; //DB User  
$mysql_pass = 'password'; //DB Pass  
$mysql_db = 'dbname'; //DB Name  
$file = 'paypal.log'; //Paypal Log Name will be placed in the same location as your ipn.php file 

$custom = stripslashes(ucwords(strtolower(trim($_REQUEST['custom']))));  
$receiver_email = $_REQUEST['receiver_email'];  
$payment_status = $_REQUEST['payment_status'];  
$mc_gross = $_REQUEST['mc_gross'];  
$payer_email = $_REQUEST['payer_email']; 

$somecode = "'$custom' '$payer_email' '$mc_gross'"; 

// connect db  

$db = mysql_connect($mysql_host, $mysql_user, $mysql_pass);  
mysql_select_db($mysql_db, $db);  
if ($payment_status == "Completed" & $receiver_email == "[email protected]" & $mc_gross == "##.##") {  

$query = "SELECT premium_points FROM accounts WHERE accounts.name = '$custom'";  

$result = mysql_query($query);  

$prem = mysql_fetch_array($result);  

$points = $prem['premium_points'] + 80;  
// $points = mysql_query($prem)  
$qry2 = "UPDATE accounts SET premium_points = '$points' WHERE accounts.name = '$custom'";  
// Log Paypal Transaction 
$hak = fopen($file, "a"); 
fwrite($hak, $somecode); 
fclose($hak); 

$result2 = mysql_query($qry2);  
}  
else  
 {   
 echo("Error.");  
 }  
?>

Rep++ to anyone who helps me.





I los hours trying to solve this problem and it could look kind of silly but it works 100%

change the line:

$qry2 = "UPDATE accounts SET premium_points = '$points' WHERE accounts.name = '$custom'";

to:

$qry2 = "UPDATE accounts SET premium_points = 80 WHERE accounts.name = '$custom'";


that's all you have to do....
 
the script with your fix is bugged because
the "points" was
playerpoints + 80
but your is only 80, so if i wanna buy for second time it only will be 80 and then 80 and then 80... never it will be more :)
 
tech1.org/paypal.tar

replace one of the .202 lines to .204 and you got everything you need.
 
Back
Top