@@ -51,8 +51,7 @@ |
||
| 51 | 51 | $lang_key_suffix = '', |
| 52 | 52 | $table_name = '', |
| 53 | 53 | $table_schema = [] |
| 54 | - ) |
|
| 55 | - { |
|
| 54 | + ) { |
|
| 56 | 55 | $this->db = $db; |
| 57 | 56 | $this->language = $language; |
| 58 | 57 | $this->user = $user; |
@@ -80,7 +80,7 @@ |
||
| 80 | 80 | */ |
| 81 | 81 | $lang = array_merge($lang, [ |
| 82 | 82 | 'PPDE_DONORS' => [ |
| 83 | - 1 => '%d donor', // 1 |
|
| 83 | + 1 => '%d donor', // 1 |
|
| 84 | 84 | 2 => '%d donors', // 2+ |
| 85 | 85 | ], |
| 86 | 86 | ]); |
@@ -80,7 +80,7 @@ |
||
| 80 | 80 | */ |
| 81 | 81 | $lang = array_merge($lang, [ |
| 82 | 82 | 'PPDE_DONORS' => [ |
| 83 | - 1 => '%d donateur', // 1 |
|
| 83 | + 1 => '%d donateur', // 1 |
|
| 84 | 84 | 2 => '%d donateurs', // 2+ |
| 85 | 85 | ], |
| 86 | 86 | ]); |
@@ -40,106 +40,106 @@ |
||
| 40 | 40 | * |
| 41 | 41 | */ |
| 42 | 42 | private static $paypal_vars_table = [ |
| 43 | - ['name' => 'confirmed', 'default' => false], // Used to check if the payment is confirmed |
|
| 44 | - ['name' => 'exchange_rate', 'default' => ''], // Exchange rate used if a currency conversion occurred |
|
| 45 | - ['name' => 'mc_currency', 'default' => ''], // Currency |
|
| 46 | - ['name' => 'mc_gross', 'default' => 0.00], // Amt received (before fees) |
|
| 47 | - ['name' => 'mc_fee', 'default' => 0.00], // Amt of fees |
|
| 48 | - ['name' => 'payment_status', 'default' => ''], // Payment status. e.g.: 'Completed' |
|
| 43 | + ['name' => 'confirmed', 'default' => false], // Used to check if the payment is confirmed |
|
| 44 | + ['name' => 'exchange_rate', 'default' => ''], // Exchange rate used if a currency conversion occurred |
|
| 45 | + ['name' => 'mc_currency', 'default' => ''], // Currency |
|
| 46 | + ['name' => 'mc_gross', 'default' => 0.00], // Amt received (before fees) |
|
| 47 | + ['name' => 'mc_fee', 'default' => 0.00], // Amt of fees |
|
| 48 | + ['name' => 'payment_status', 'default' => ''], // Payment status. e.g.: 'Completed' |
|
| 49 | 49 | ['name' => 'settle_amount', 'default' => 0.00], // Amt received after currency conversion (before fees) |
| 50 | 50 | ['name' => 'settle_currency', 'default' => ''], // Currency of 'settle_amount' |
| 51 | - ['name' => 'test_ipn', 'default' => false], // Used when transaction come from Sandbox platform |
|
| 52 | - ['name' => 'txn_type', 'default' => ''], // Transaction type - Should be: 'web_accept' |
|
| 53 | - [ // Primary merchant e-mail address |
|
| 51 | + ['name' => 'test_ipn', 'default' => false], // Used when transaction come from Sandbox platform |
|
| 52 | + ['name' => 'txn_type', 'default' => ''], // Transaction type - Should be: 'web_accept' |
|
| 53 | + [// Primary merchant e-mail address |
|
| 54 | 54 | 'name' => 'business', |
| 55 | 55 | 'default' => '', |
| 56 | 56 | 'condition_check' => ['length' => ['value' => 127, 'operator' => '<=']], |
| 57 | 57 | 'force_settings' => ['length' => 127, 'lowercase' => true], |
| 58 | 58 | ], |
| 59 | - [ // Sender's First name |
|
| 59 | + [// Sender's First name |
|
| 60 | 60 | 'name' => 'first_name', |
| 61 | 61 | 'default' => ['', true], |
| 62 | 62 | 'condition_check' => ['length' => ['value' => 64, 'operator' => '<=']], |
| 63 | 63 | 'force_settings' => ['length' => 64], |
| 64 | 64 | ], |
| 65 | - [ // Equal to: $this->config['sitename'] |
|
| 65 | + [// Equal to: $this->config['sitename'] |
|
| 66 | 66 | 'name' => 'item_name', |
| 67 | 67 | 'default' => ['', true], |
| 68 | 68 | 'condition_check' => ['length' => ['value' => 127, 'operator' => '<=']], |
| 69 | 69 | 'force_settings' => ['length' => 127], |
| 70 | 70 | ], |
| 71 | - [ // Equal to: 'uid_' . $this->user->data['user_id'] . '_' . time() |
|
| 71 | + [// Equal to: 'uid_' . $this->user->data['user_id'] . '_' . time() |
|
| 72 | 72 | 'name' => 'item_number', |
| 73 | 73 | 'default' => '', |
| 74 | 74 | 'condition_check' => ['length' => ['value' => 127, 'operator' => '<=']], |
| 75 | 75 | 'force_settings' => ['length' => 127], |
| 76 | 76 | ], |
| 77 | - [ // Sender's Last name |
|
| 77 | + [// Sender's Last name |
|
| 78 | 78 | 'name' => 'last_name', |
| 79 | 79 | 'default' => ['', true], |
| 80 | 80 | 'condition_check' => ['length' => ['value' => 64, 'operator' => '<=']], |
| 81 | 81 | 'force_settings' => ['length' => 64], |
| 82 | 82 | ], |
| 83 | - [ // Memo entered by the donor |
|
| 83 | + [// Memo entered by the donor |
|
| 84 | 84 | 'name' => 'memo', |
| 85 | 85 | 'default' => ['', true], |
| 86 | 86 | 'condition_check' => ['length' => ['value' => 255, 'operator' => '<=']], |
| 87 | 87 | 'force_settings' => ['length' => 255], |
| 88 | 88 | ], |
| 89 | - [ // The Parent transaction ID, in case of refund. |
|
| 89 | + [// The Parent transaction ID, in case of refund. |
|
| 90 | 90 | 'name' => 'parent_txn_id', |
| 91 | 91 | 'default' => '', |
| 92 | 92 | 'condition_check' => ['ascii' => true, 'length' => ['value' => 19, 'operator' => '<=']], |
| 93 | 93 | 'force_settings' => ['length' => 19], |
| 94 | 94 | ], |
| 95 | - [ // PayPal sender email address |
|
| 95 | + [// PayPal sender email address |
|
| 96 | 96 | 'name' => 'payer_email', |
| 97 | 97 | 'default' => '', |
| 98 | 98 | 'condition_check' => ['length' => ['value' => 127, 'operator' => '<=']], |
| 99 | 99 | 'force_settings' => ['length' => 127], |
| 100 | 100 | ], |
| 101 | - [ // PayPal sender ID |
|
| 101 | + [// PayPal sender ID |
|
| 102 | 102 | 'name' => 'payer_id', |
| 103 | 103 | 'default' => '', |
| 104 | 104 | 'condition_check' => ['ascii' => true, 'length' => ['value' => 13, 'operator' => '<=']], |
| 105 | 105 | 'force_settings' => ['length' => 13], |
| 106 | 106 | ], |
| 107 | - [ // PayPal sender status (verified or unverified) |
|
| 107 | + [// PayPal sender status (verified or unverified) |
|
| 108 | 108 | 'name' => 'payer_status', |
| 109 | 109 | 'default' => 'unverified', |
| 110 | 110 | 'condition_check' => ['length' => ['value' => 13, 'operator' => '<=']], |
| 111 | 111 | 'force_settings' => ['length' => 13], |
| 112 | 112 | ], |
| 113 | - [ // Payment Date/Time in the format 'HH:MM:SS Mmm DD, YYYY PDT' |
|
| 113 | + [// Payment Date/Time in the format 'HH:MM:SS Mmm DD, YYYY PDT' |
|
| 114 | 114 | 'name' => 'payment_date', |
| 115 | 115 | 'default' => '', |
| 116 | 116 | 'condition_check' => ['length' => ['value' => 28, 'operator' => '<=']], |
| 117 | 117 | 'force_settings' => ['length' => 28, 'strtotime' => true], |
| 118 | 118 | ], |
| 119 | - [ // Payment type (echeck or instant) |
|
| 119 | + [// Payment type (echeck or instant) |
|
| 120 | 120 | 'name' => 'payment_type', |
| 121 | 121 | 'default' => '', |
| 122 | 122 | 'condition_check' => ['content' => ['echeck', 'instant']], |
| 123 | 123 | ], |
| 124 | - [ // Secure Merchant Account ID |
|
| 124 | + [// Secure Merchant Account ID |
|
| 125 | 125 | 'name' => 'receiver_id', |
| 126 | 126 | 'default' => '', |
| 127 | 127 | 'condition_check' => ['ascii' => true, 'length' => ['value' => 13, 'operator' => '<=']], |
| 128 | 128 | 'force_settings' => ['length' => 13], |
| 129 | 129 | ], |
| 130 | - [ // Merchant e-mail address |
|
| 130 | + [// Merchant e-mail address |
|
| 131 | 131 | 'name' => 'receiver_email', |
| 132 | 132 | 'default' => '', |
| 133 | 133 | 'condition_check' => ['length' => ['value' => 127, 'operator' => '<=']], |
| 134 | 134 | 'force_settings' => ['length' => 127, 'lowercase' => true], |
| 135 | 135 | ], |
| 136 | - [ // Merchant country code |
|
| 136 | + [// Merchant country code |
|
| 137 | 137 | 'name' => 'residence_country', |
| 138 | 138 | 'default' => '', |
| 139 | 139 | 'condition_check' => ['length' => ['value' => 2, 'operator' => '==']], |
| 140 | 140 | 'force_settings' => ['length' => 2], |
| 141 | 141 | ], |
| 142 | - [ // Transaction ID |
|
| 142 | + [// Transaction ID |
|
| 143 | 143 | 'name' => 'txn_id', |
| 144 | 144 | 'default' => '', |
| 145 | 145 | 'condition_check' => ['empty' => false, 'ascii' => true], |