-1

I am integrating realex payment in PHP and I'm using hpp method I have integrated but how can I get response message?

Payment is success, I got blank screen. The link is https://pay.sandbox.realexpayments.com/card.html?guid=3753cf95-d9d3-41bf-b573-64dbd23b7803

How do I get response json?

Global Payments
  • 500
  • 2
  • 10
venpep
  • 1
  • 1
  • 4
    Welcome to stackoverflow. Please, could you provide some code of your specific problem. That prove how far did you try and it will help other members to understand your problem better, at the time, you will give them a context of your issue. Please, check these links: https://stackoverflow.com/help/mcve and https://stackoverflow.com/help/how-to-ask – Kenzo_Gilead Sep 22 '17 at 11:49

1 Answers1

0

Thanks for your question. If you're not using our SDKs and Libraries, you can include MERCHANT_RESPONSE_URL in your request POST to HPP. This will set a URL in your application the transaction response can be sent to. Please refer to https://developer.realexpayments.com/#!/hpp/transaction-processing

If you're loading the HPP in an iFrame, you can trigger the response to be sent to the parent frame. Please refer to https://developer.realexpayments.com/#!/hpp/customization/hpp-iframe-webview-optimization

Global Payments
  • 500
  • 2
  • 10
  • Do I need to provide a response URL for the message to be sent to the parent frame? – Spurious May 17 '18 at 19:06
  • In your request POST to you'll need to provide the domain that's calling the HPP in HPP_POST_RESPONSE field. For example "https://www.example.com" – Global Payments May 18 '18 at 09:29
  • @GlobalPayments I use HPP_POST_RESPONSE in form tag, I used localhost URL in that, But it does not redirect in that given URL in HPP_POST_RESPONSE , no any response I get, I am using iFrame for load "https://pay.sandbox.realexpayments.com/pay" this URL, when payment success then all content get hidden and iFrame remain blank but no response received in given URL, Can you please help? – Gaurav Radadiya May 17 '20 at 08:54
  • @Spurious If you can get response with using HPP_POST_RESPONSE then please tell me How did you archive this? – Gaurav Radadiya May 17 '20 at 08:56
  • @GauravRadadiya sorry, only seeing this now. It's been ages since I've actually done it, but I got it working in the end. I used a response URL which was exactly the same URL as the site was hosted on. Not sure if that is necessary, but this worked for me. I added an event listener for message that handled the result. `window.addEventListener('message', function(e) {...}` – Spurious Jun 20 '20 at 16:29