Advanced implementation

 

Overview
How to use the advanced implementation
Parameters description
IPN
IPN Parameters description

 


 

Overview

Our advanced implementation is a white label payments solution which allows you to redirect your customers directly to a local payment method with no need to open the PayGol payment screen.

Please note that our advanced implementation can be used with “Integrated” type services only.

 

How to use the advanced implementation

First you must create a new “Integrated” type service, you can do this here.
Below is a sample code for your payment button. Just replace any placeholder values as needed and you are ready to charge.
You can test your service by clicking on the button. Additionally, please note that you can always edit your service from your control panel, where you will be able to control on which countries you want to charge and which payment methods you want to accept.

<form name="pg_frm" method="post" action="https://www.paygol.com/pay" >
   <input type="hidden" name="pg_serviceid" value="123">
   <input type="hidden" name="pg_currency" value="EUR">
   <input type="hidden" name="pg_custom" value="">
   <input type="hidden" name="pg_price" value="1">
   <input type="hidden" name="pg_return_url" value="http://www.paygol.com/webapps/implementation">
   <input type="hidden" name="pg_cancel_url" value="">
   <input type="hidden" name="pg_mode" value="advanced">
   <input type="hidden" name="pg_country" value="GB">
   <input type="hidden" name="pg_method" value="creditcard">
   Email: <input type="text" name="pg_email"><br><br>
   Personal ID: <input type="text" name="pg_personalid"><br><br>
   <input type="image" name="pg_button" src="https://www.paygol.com/webapps/img/buttons/150/black_en_pbm.png" border="0" alt="Make payments with PayGol: the easiest way!" title="Make payments with PayGol: the easiest way!" >     
</form>
 

Parameters description

The following POST/GET parameters are required:

 

Codes for available payment methods:

Name Code Description
 

IPN

What is IPN?
Instant Payment Notification (IPN) is a message service that notifies you of events related to PayGol transactions. You can use it to automate back-office and administrative functions, such as fulfilling orders, inserting points or coins, upgrading membership, tracking customers, and providing status and other information related to a transaction.

Information about the payment
PayGol makes a GET request to your IPN file when your customer completes the transaction. You can use this notification to kick-off order fulfillment, enable digital media downloads, store information in a customer relationship management (CRM) or accounting system, and so on.

How to receive the IPN information in my web page?
PayGol provides samples of Instant Payment Notification (IPN) code for popular development environments. Use working sample code to speed up your PayGol integrations.

Example:

<?php 

$secret_key = "aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeee";  // Enter secret key for your service. 

// Secret key validation 
if ($secret_key != $_GET['key']) {
    echo "Validation error"; 
    exit;
}


// get the variables from PayGol system
$transaction_id	  = $_GET['transaction_id'];
$service_id	      = $_GET['service_id'];
$country	         = $_GET['country'];
$custom	          = $_GET['custom'];
$price	           = $_GET['price'];
$currency	        = $_GET['currency'];
$frmprice	        = $_GET['frmprice'];
$frmcurrency	     = $_GET['frmcurrency'];

// Here you can do whatever you want with the variables, for instance inserting or updating data into your Database 

?>
 

IPN Parameters description