1
0
-1

Is it possible to trap a REJECTED payment coming from Worldpay in the form journey and redirect elsewhere (in this case to another form) ?

    CommentAdd your comment...

    1 answer

    1.  
      1
      0
      -1

      TM will treat a REJECTED payment as a payment error and will take the user back to the make payment page where they can try again. This can not be intercepted without code changes unless Worldpay can be configured to do this rather than returning to the standard TM servlet.

      For the Worldpay gateway it is possible to customise the XML payload that is sent by TM to initiate the payment. See the paymentRequestTemplate parameter on the service definition. It may be possible to add to this to control Worldpays response. You would need to look in the Worldpay doco to see if this is possible. 

      You could also inject some javascript into the page markup for the payment page to inspect the payment error that is presented to the user and forward the user to another page/url. This could end up being a fragile solution as if would be dependant on the error string presented to the user.

       

       

        CommentAdd your comment...