Try redirect to Checkout Link

To verify that your integration is going through as expected, after generating the checkout link. Next, we going to make some redirect request to that checkout link. If the request is successful you will redirect to PAYON's payment page.

Include PAYON's library

Add PAYON's lib helper for client side to your check out page.

  <script th:src="@{../js/payonUtils.js}" charset="utf-8" type="text/javascript"></script>

Prepare your Checkout Page

<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org">
<body>
    <button class="btn btn-primary" id= "checkOut">Check Out</button>  	
    <button class="btn btn-primary" id= "payonnCheckOut">PAY with PAYON</button>
    <button class="btn btn-primary" id= "creditDebitCheckOut">PAY with Credit/Debit</button>
    <button class="btn btn-primary" id= "pgBindingCheckOut">PAY with Credit/Debit</button>
    <button class="btn btn-primary" id= "pgBtCheckOut">PAY with Bank Transfer</button>
   
</body>
</html>

Prepare your Checkout script

In order to process this step. First, you need to Checkout Link endpoint in step 2. This endpoint will be on back end side implementation.

JavaScript

PHP

Prepare your PAYON's Wallet Checkout Script

Prepare your Credit/Debit's Checkout Script

Prepare your Binding Payment Script

Prepare your Bank Transfer Check out Script

Last updated

Was this helpful?