Example #1
0
 function getEpayErrorText($errorcode)
 {
     $res = "Unable to lookup errorcode";
     try {
         $client = new SoapClient('https://ssl.ditonlinebetalingssystem.dk/remote/payment.asmx?WSDL');
         $param = array('merchantnumber' => $this->getConfigData('merchantnumber', $this->getOrder() ? $this->getOrder()->getStoreId() : null), 'language' => $this->calcLanguage(Mage::app()->getLocale()->getLocaleCode()), 'epayresponsecode' => $errorcode, 'epayresponsestring' => 0, 'epayresponse' => 0, 'pwd' => $this->getConfigData('remoteinterfacepassword', $this->getOrder() ? $this->getOrder()->getStoreId() : null));
         $client = new SoapClient('https://ssl.ditonlinebetalingssystem.dk/remote/payment.asmx?WSDL');
         $result = $client->getEpayError($param);
         if ($result->getEpayErrorResult == 1) {
             $res = $result->epayresponsestring;
         }
     } catch (Exception $e) {
         return $res;
     }
     return $res;
 }