Iframe Payment Gateway


I'm Building a new payment gateway integration with cs-cart multivendor v4.11.3 and i want to use the iframe option.

I followed the documentation at https://docs.cs-cart.com/latest/developer_guide/addons/tutorials/payment_processor_addon.html?highlight=iframe_mode#iframe-mode-for-a-payment-processor

and the sample addon code at https://github.com/cscart/addons/tree/master/iframe_payment

in the payment processor script i added the code to send the request with the required information to the payment gateway by pressing on place order in the checkout page and i'm getting a success response with a json that resembles the following:


In the sample addon example they have 2 flags PAYMENT_NOTIFICATION which will be defined when the payment_notification controller is executed and IFRAME_MODE that it is not mentioned in any place how and when to define it.

How can activate or insert the iframe with the url returned from the gateway in the checkout page to add the card details and proceed with the payment?

Try to use something like

$response = json_decode($response, true);