-
Notifications
You must be signed in to change notification settings - Fork 12
/
Copy pathresponse_paypal_user.php
38 lines (34 loc) · 1.43 KB
/
response_paypal_user.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
<?php
/************************************************************************/
/* ATutor */
/************************************************************************/
/* Copyright (c) 2002 - 2013 */
/* ATutorSpaces */
/* https://atutorspaces.com */
/* This program is free software. You can redistribute it and/or */
/* modify it under the terms of the GNU General Public License */
/* as published by the Free Software Foundation. */
/************************************************************************/
$_user_location = 'users';
define('AT_INCLUDE_PATH', '../../include/');
require(AT_INCLUDE_PATH.'vitals.inc.php');
require('include/payments.lib.php');
$transaction_id = $addslashes($_REQUEST['tx']);
$payment_id = intval($_REQUEST['item_number']);
if ($_GET['st'] == "Completed"){
approve_payment($payment_id, $transaction_id);
$msg->addFeedback('ACTION_COMPLETED_SUCCESSFULLY');
} else if ($_GET['st'] == "Pending"){
approve_payment($payment_id, $transaction_id);
$msg->addFeedback('ACTION_COMPLETED_SUCCESSFULLY');
$msg->addFeedback('ACTION_PENDING_CC_CONFIRM');
}else {
$msg->addError('EC_PAYMENT_FAILED');
}
unset($_SESSION['payment_id']);
unset($_SESSION['seats_requested']);
//print_r($_GET);
//exit;
header('Location: index.php');
exit;
?>