On-Page Hosting for Hosted Pay Page

 Hi,

I've seen bits of text referring to being able to embed a hosted pay page in an iframe on the merchant site. For example, on the Hosted Solutions page in the docs, it refers to:

Merchants have the option to embed the payment form within an iFrame on their checkout page. The Hosted Pay Page still resides on Moneris’ secure servers but the transition to the Moneris secure page is invisible to the cardholder.

The particular example we are looking at is under On-Page Hosting in this blog post: http://insights.moneris.com/h/i/239037442-the-ins-and-outs-what-is-a-hosted-pay-page

But I've been digging around, and couldn't really find a way to embed a hosted pay page in an iframe that's as robust as the example in that blog post, aside from using Hosted Tokenization. I might have been missing it, but I could use a point in the right direction.

Thanks!

  • You could do it like this: 

    1. This is your page that includes the iframe. 

    <html>
    <head>
    <title> Outer Frame - Merchant Page</title>
    </head>
    <body>
    <div>This is the outer page</div>
    <div id=monerisResponse></div>
    <iframe title="moneris" id="monerisFrame" src="hostedPayPagePost.html" width="800" height="800"></iframe>
    </body>
    </html>

       2. The "hostedPayPagePost.html" file would have the POST to the HPP (examples here). To ensure that the HPP loads in the iframe, set the form's target attribute to _self as such:

    <FORM METHOD="POST" ACTION= "esqa.moneris.com/.../index.php" TARGET="_self">

  • In reply to ME_Moneris:

    I used the same way but I have got moneris receipt.

    Is this possible that I can catch the moneris response via JavaScript event lisntener?

    based on response I want to redirect to another page for more processing.
  • In reply to eDevAbidAli:

    The only options for Hosted Paypage responses are the ones in the configuration (Post, post with XML, Get).

    If you are looking for a javascript event response you should really have a look at our Moneris Checkout product. It basically requires a preload call, then you display the page within am iFrame (div). You can find the documentation on our github through the developer portal. The documentation should be updated very shortly with better details, the current release is a review draft.