1 | <?php |
||
2 | /* |
||
3 | * ipn.php |
||
4 | * |
||
5 | * PHP Toolkit for PayPal v0.51 |
||
6 | * http://www.paypal.com/pdn |
||
7 | * |
||
8 | * Copyright (c) 2004 PayPal Inc |
||
9 | * |
||
10 | * Released under Common Public License 1.0 |
||
11 | * http://opensource.org/licenses/cpl.php |
||
12 | * |
||
13 | */ |
||
14 | include __DIR__ . '/header.php'; |
||
15 | require_once XOOPS_ROOT_PATH . '/class/module.errorhandler.php'; |
||
0 ignored issues
–
show
Bug
introduced
by
![]() |
|||
16 | $myts = MyTextSanitizer::getInstance();// MyTextSanitizer object |
||
0 ignored issues
–
show
The type
MyTextSanitizer was not found. Maybe you did not declare it correctly or list all dependencies?
The issue could also be caused by a filter entry in the build configuration.
If the path has been excluded in your configuration, e.g. filter:
dependency_paths: ["lib/*"]
For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths ![]() |
|||
17 | |||
18 | require_once __DIR__ . '/class/class.subscription.php'; |
||
19 | |||
20 | $eh = new ErrorHandler; |
||
0 ignored issues
–
show
The type
ErrorHandler was not found. Maybe you did not declare it correctly or list all dependencies?
The issue could also be caused by a filter entry in the build configuration.
If the path has been excluded in your configuration, e.g. filter:
dependency_paths: ["lib/*"]
For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths ![]() |
|||
21 | //get global configuration information |
||
22 | require_once __DIR__ . '/paypal_includes/global_config.inc.php'; |
||
23 | |||
24 | //get pay pal configuration file |
||
25 | require_once __DIR__ . '/paypal_includes/config.inc.php'; |
||
26 | |||
27 | //decide which post method to use |
||
28 | View Code Duplication | switch ($paypal['post_method']) { |
|
29 | |||
30 | case 'libCurl': //php compiled with libCurl support |
||
31 | |||
32 | $result = libCurlPost($paypal['url'], $_POST); |
||
33 | |||
34 | break; |
||
35 | |||
36 | case 'curl': //cURL via command line |
||
37 | |||
38 | $result = curlPost($paypal['url'], $_POST); |
||
39 | //print_r($result); |
||
40 | break; |
||
41 | |||
42 | case 'fso': //php fsockopen(); |
||
43 | |||
44 | $result = fsockPost($paypal['url'], $_POST); |
||
45 | //print_r($result); |
||
46 | break; |
||
47 | |||
48 | default: //use the fsockopen method as default post method |
||
49 | |||
50 | $result = fsockPost($paypal['url'], $_POST); |
||
51 | //print_r($result); |
||
52 | break; |
||
53 | |||
54 | } |
||
55 | |||
56 | //check the ipn result received back from paypal |
||
57 | |||
58 | if (eregi('VERIFIED', $result)) { |
||
59 | // Automatic update of the subscription is not yet included in the success page. |
||
60 | // This will need to be done manually. |
||
61 | require_once __DIR__ . '/ipn/ipn_success.php'; |
||
62 | } else { |
||
63 | require_once __DIR__ . '/ipn/ipn_error.php'; |
||
64 | } |
||
65 |