/** * Ejecuta un pago por web service con la operativa DCC * @param int $idpayuser Id del usuario en PAYTPV * @param string $tokenpayuser Token del usuario en PAYTPV * @param string $amount Importe del pago 1€ = 100 * @param string $transreference Identificador único del pago * @param string $productdescription Descripción del producto * @param string $owner Titular de la tarjeta * @return object Objeto de respuesta de la operación * @version 1.0 2016-06-07 */ public function ExecutePurchaseDcc($idpayuser, $tokenpayuser, $amount, $transreference, $productdescription = false, $owner = false) { $signature = sha1($this->merchantCode . $idpayuser . $tokenpayuser . $this->terminal . $amount . $transreference . $this->password); $ip = $_SERVER['REMOTE_ADDR']; try { $clientSOAP = new SoapClient($this->endpoint); $ans = $clientSOAP->execute_purchase_dcc($this->merchantCode, $this->terminal, $idpayuser, $tokenpayuser, $amount, $transreference, $signature, $ip, $productdescription, $owner); } catch (SoapFault $e) { return $this->SendResponse(); } return $this->SendResponse($ans); }