• 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!

[Geisor] Need help with the Paygol system.

strix raider

New Member
Joined
Mar 1, 2009
Messages
39
Reaction score
0
So I've set up the whole paygol system and everything.

The only problem I have now is that when someone donates they don't get any points.


This is my following set-up

10 points - 2 euro
20 points -3 euro
30 points - 4 euro
40 points -5 euro
50 points -6 euro

PHP:
<?php
/*
English:
This script will help you to integrate PayGol as your sms payment gateway in your Tibia, users can donate and they can have their points in-game, this mean they don't have to wait hours or even days to get their points.
Please read this link http://www.slideshare.net/paygol/paygol-automatic-sms-payments-in-tibia which will guide you step by step.

Note:Before starting you have to create an account at http://www.paygol.com/register

Espanol:
Este codigo te ayudara a integrar PayGol como tu plataforma de pagos por sms en tu Tibia, tus usuarios podran donar y podran obtener sus puntos de inmediato, no tendran que esperar horas o hasta dias para obtener sus puntos.
Por favor, lee esta guia http://www.slideshare.net/paygol/paygol-automatic-smspaymentsintibiaes que te ayudara paso a paso..

Nota:Antes de comenzar, debes crear una cuenta en http://www.paygol.com/register
*/


// check that the request comes from PayGol server
if(!in_array($_SERVER['REMOTE_ADDR'],
  array('109.70.3.48', '109.70.3.146', '109.70.3.58'))) {
  header("HTTP/1.0 403 Forbidden");
  die("Error: Unknown IP");
}
  

//Get all parameters from PayGol
$message_id	= $_GET[message_id];
$shortcode	= $_GET[shortcode];
$keyword		= $_GET[keyword];
$message		= $_GET[message];
$sender			= $_GET[sender];
$operator		= $_GET[operator];
$country		= $_GET[country];
$custom	    = $_GET[custom];//
$price			= $_GET[price];
$currency		= $_GET[currency];
$points		  = $_GET[points];

//Replace these parameters by your database details
$dbhost     = "localhost"; //Your database domain
$dbuser     = "SECRET"; //Database username
$dbpassword = "SECRET"; //Database password
$db         = "SECRET"; //Database name

//Connect to Database
$conn = mysql_connect($dbhost, $dbuser, $dbpassword);
mysql_select_db($db);

$sql = "UPDATE accounts SET premium_points = premium_points+$points WHERE name = '$custom'";
mysql_query($sql);

mysql_close($conn);

?>
 
Back
Top