Hi,
I used this script for paygol from someone here for my Gesior ACC. But when someone buy points, it takes the money and no give any points.
Also if it possible to make it work with login ( you must login ) instead of writing account number.
I am using TFS 0.3.7 and Gesior version 1.0.3 for TFS 0.4 revision 3703+
This is paygol.php
This is paygolshop.php
Any help?
I used this script for paygol from someone here for my Gesior ACC. But when someone buy points, it takes the money and no give any points.
Also if it possible to make it work with login ( you must login ) instead of writing account number.
I am using TFS 0.3.7 and Gesior version 1.0.3 for TFS 0.4 revision 3703+
This is paygol.php
Code:
<?php
/*
Note:Before starting you have to create an account at http://www.paygol.com/register?affiliatecode=T8Y7-LK0M-NY0R-Y6O3
*/
// 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");
}
// CONFIG
$your_service_id = 50640; // Your service ID from Paygol
// get the variables from PayGol system
$message_id = $_GET['message_id'];
$service_id = $_GET['service_id'];
$shortcode = $_GET['shortcode'];
$keyword = $_GET['keyword'];
$message = $_GET['message'];
$sender = $_GET['sender'];
$operator = $_GET['operator'];
$country = $_GET['country'];
$custom = $_GET['custom'];
$points = $_GET['points'];
$price = $_GET['price'];
$currency = $_GET['currency'];
//Replace these parameters by your database details
$dbhost = "localhost"; //Your database domain
$dbuser = "Database"; //Database username
$dbpassword = "Database"; //Database password
$db = "Database"; //Database name
if ($your_service_id == $service_id) {
//Connect to Database
$conn = mysql_connect($dbhost, $dbuser, $dbpassword);
mysql_select_db($db);
$sql = "UPDATE accounts SET premium_points = premium_points+'".mysql_real_escape_string($points)."' WHERE name = '".mysql_real_escape_string($custom)."'";
mysql_query($sql);
mysql_close($conn);
}
?>
Code:
<?PHP
$main_content .= '
<b>Buy Premium Points by PayGol Now.</b></CENTER><br /><br />
<ol>
<li>Enter your account number.</li>
<li>Choose your payment price.</li>
<li>Click on the PAY button of PayGol.</li>
<li>Follow the instructions.</li>
<li>Your points will be added automatically.</li>
<li><font color=red><B>DONT FORGET TO PUT IN YOUR ACCOUNT NUMBER! IF YOU DONT DO IT YOU WONT GET ANY POINTS!</B></font></li>
<li><font color=red><B>IF YOU FORGET TO PUT IN YOUR ACCOUNT NUMBER, NO ONE WILL GIVE YOU POINTS!</B></font></li>
</ol>
</br>
<center><b><li>30 Premium Points For 5 Euro</li>
<li>60 Premium Points For 10 Euro</li>
<li>100 Premium Points For 20 Euro</li>
</center></b>
</br>
';
$main_content .= '<center>
<!-- PayGol JavaScript -->
<script src="http://www.paygol.com/micropayment/js/paygol.js" type="text/javascript"></script>
<!-- PayGol Form -->
<form name="pg_frm">
<h1>Enter account number:</h1><p>
<input type="text" name="pg_custom" value=""><p>
<input type="hidden" name="pg_serviceid" value="50640">
<input type="hidden" name="pg_currency" value="EUR">
<input type="hidden" name="pg_name" value="Premium Points">
<!-- With Option buttons -->
<input type="radio" name="pg_price" value="1"checked>30 Premium Points For 5 Euro<p>
<input type="radio" name="pg_price" value="2">60 Premium Points For 10 Euro<p>
<input type="radio" name="pg_price" value="3">100 Premium Points For 20 Euro<p>
<input type="hidden" name="pg_return_url" value="http://localhost/?subtopic=shopsystem">
<input type="hidden" name="pg_cancel_url" value="http://localhost/?subtopic=latestnews">
<input type="image" name="pg_button" class="paygol" src="http://www.paygol.com/micropayment/img/buttons/125/red_en_pbm.png" border="0" alt="Make payments with PayGol: the easiest way!" title="Make payments with PayGol: the easiest way!" onClick="pg_reDirect(this.form)">
</form> </center>';
?>
Any help?