Index: trunk/extensions/DonationInterface/globalcollect_gateway/globalcollect_gateway.body.php |
— | — | @@ -74,9 +74,6 @@ |
75 | 75 | /** |
76 | 76 | * handle PayPal redirection |
77 | 77 | * |
78 | | - * @todo |
79 | | - * - Redirect to the bank needs some error checking on the url. Verify that it is https... |
80 | | - * |
81 | 78 | * if paypal redirection is enabled ($wgPayflowProGatewayPaypalURL must be defined) |
82 | 79 | * and the PaypalRedirect form value must be true |
83 | 80 | */ |
— | — | @@ -116,47 +113,15 @@ |
117 | 114 | // allow any external validators to have their way with the data |
118 | 115 | // Execute the proper transaction code: |
119 | 116 | |
| 117 | + $result = $this->adapter->do_transaction( 'INSERT_ORDERWITHPAYMENT' ); |
| 118 | + |
| 119 | + $this->displayResultsForDebug( $result ); |
120 | 120 | |
121 | 121 | if ( $payment_method == 'cc' ) { |
122 | 122 | |
123 | | - $result = $this->adapter->do_transaction( 'INSERT_ORDERWITHPAYMENT' ); |
124 | 123 | $this->executeIframeForCreditCard( $result ); |
125 | 124 | } |
126 | | - elseif ( $payment_method == 'rtbt' ) { |
127 | 125 | |
128 | | - $result = $this->adapter->do_transaction( 'INSERT_ORDERWITHPAYMENT' ); |
129 | | - |
130 | | - $formAction = ( isset( $result['data'] ) && isset($result['data']['FORMACTION']) ) ? $result['data']['FORMACTION'] : ''; |
131 | | - |
132 | | - // Redirect to the bank |
133 | | - if ( !empty( $formAction ) ) { |
134 | | - return $wgOut->redirect( $formAction ); |
135 | | - } |
136 | | - |
137 | | - } |
138 | | - elseif ( $payment_method == 'dd' ) { |
139 | | - |
140 | | - $result = $this->adapter->do_transaction( 'DO_BANKVALIDATION' ); |
141 | | - |
142 | | - if ( isset( $result['status'] ) && $result['status'] ) { |
143 | | - |
144 | | - $result = $this->adapter->do_transaction( 'INSERT_ORDERWITHPAYMENT' ); |
145 | | - } |
146 | | - |
147 | | - } |
148 | | - else { |
149 | | - $result = $this->adapter->do_transaction( 'INSERT_ORDERWITHPAYMENT' ); |
150 | | - } |
151 | | - |
152 | | - $this->displayResultsForDebug( $result ); |
153 | | - |
154 | | - if ( isset( $result['status'] ) && $result['status'] ) { |
155 | | - $thankyoupage = $this->adapter->getGlobal( 'ThankYouPage' ); |
156 | | - |
157 | | - if ( $thankyoupage ) { |
158 | | - $wgOut->redirect( $thankyoupage . "/" . $data['language'] ); |
159 | | - } |
160 | | - } |
161 | 126 | } |
162 | 127 | } else { |
163 | 128 | // Display form for the first time |