X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=CRM%2FCore%2FPayment%2FPayflowPro.php;h=2020b2a8cd81d9ae53c3d33c68b8b37fe2eaefc8;hb=f14a8cc5397fca2a4ed9ea754337730c3285aff8;hp=2fcdf724084bed9138a4353755af8aef66ea2609;hpb=f8c5db351d0a87543cbe3af27ba30474d0f8ac4e;p=civicrm-core.git diff --git a/CRM/Core/Payment/PayflowPro.php b/CRM/Core/Payment/PayflowPro.php index 2fcdf72408..2020b2a8cd 100644 --- a/CRM/Core/Payment/PayflowPro.php +++ b/CRM/Core/Payment/PayflowPro.php @@ -567,85 +567,4 @@ class CRM_Core_Payment_PayflowPro extends CRM_Core_Payment { return $responseData; } - /** - * @param int $recurringProfileID - * @param int $processorID - * - * @throws Exception - */ - public function getRecurringTransactionStatus($recurringProfileID, $processorID) { - if (!defined('CURLOPT_SSLCERT')) { - CRM_Core_Error::fatal(ts('Payflow Pro requires curl with SSL support')); - } - - /* - * define variables for connecting with the gateway - */ - - //if you have not set up a separate user account the vendor name is used as the username - if (!$this->_paymentProcessor['subject']) { - $user = $this->_paymentProcessor['user_name']; - } - else { - $user = $this->_paymentProcessor['subject']; - } - //$recurringProfileID = "RT0000000001"; - // c $trythis = $this->getRecurringTransactionStatus($recurringProfileID,17); - - /* - *Create the array of variables to be sent to the processor from the $params array - * passed into this function - * - */ - - $payflow_query_array = array( - 'USER' => $user, - 'VENDOR' => $this->_paymentProcessor['user_name'], - 'PARTNER' => $this->_paymentProcessor['signature'], - 'PWD' => $this->_paymentProcessor['password'], - // C - Direct Payment using credit card - 'TENDER' => 'C', - // A - Authorization, S - Sale - 'TRXTYPE' => 'R', - 'ACTION' => 'I', - //A for add recurring - //(M-modify,C-cancel,R-reactivate, - //I-inquiry,P-payment - 'ORIGPROFILEID' => $recurringProfileID, - 'PAYMENTHISTORY' => 'Y', - ); - - $payflow_query = $this->convert_to_nvp($payflow_query_array); - echo $payflow_query; - $submiturl = $this->_paymentProcessor['url_site']; - //ie. url at payment processor to submit to. - $responseData = self::submit_transaction($submiturl, $payflow_query); - /* - * Payment successfully sent to gateway - process the response now - */ - - $result = strstr($responseData, "RESULT"); - $nvpArray = array(); - while (strlen($result)) { - // name - $keypos = strpos($result, '='); - $keyval = substr($result, 0, $keypos); - // value - $valuepos = strpos($result, '&') ? strpos($result, '&') : strlen($result); - $valval = substr($result, $keypos + 1, $valuepos - $keypos - 1); - // decoding the respose - $nvpArray[$keyval] = $valval; - $result = substr($result, $valuepos + 1, strlen($result)); - } - - // @TODO Function is named getRecurringTransactionStatus() which - // suggests it returns a result. It sets a $result_code but doesn't return - // it, printing output instead? - $result_code = $nvpArray['RESULT']; - print_r($responseData); - - //RESPMSG=Invalid Profile ID: Invalid recurring profile ID - //RT0000000001 - } - }