Search code examples
woocommercepayfort

Payfort integration in wooCommerce | Showing error on checkout, and order pending for 3d Secure response


I am integrating payfort in wooCommerce site, I have installed the payfort plugin, and configured according to my payfort test account settings. Now on checkout its showing error

There are some issues with the items in your cart. Please go back to the cart page and resolve these issues before checking out.

I tried to check order history on wooCommerce which showing transaction status pending, then I checked on payfort test account logs, and I found the response for this transaction was sent with response_message 3d secure check requested.

Now I wonder how to handle payfort response on wooCommerce side while integration type is MerchantPage 2.0, which I am expecting to handle the response itself.

I need little help to understand the payfort integration process, as my search couldn't find any help online.

Thanks in advance

  • I have emailed Payfort support center, but as its weekend, the response will be late.

Solution

  • The issue resolved finally, let me share the solution.

    Issue: In this plugin payment.php file has a function callApi($postData, $gatewayUrl) which is sending request to payfort to notify and parsing response to json

    $array_result = json_decode($response, true);

    while the response was coming in XML format so it was returning null to $array_result.

    Solution: To resolve the above issue in Payfort account settings, under Account Setup > Technical Settings enable Json for response type.

    Suggestion: Plugin should be updated to configured with this settings as well, if an account settings is with XML response type, then response should be parse accordingly.