PHP Classes

File: authorize_ipn.php

Recommend this page to a friend!
  Classes of Md Emran Hasan   Payment Gateway Library   authorize_ipn.php   Download  
File: authorize_ipn.php
Role: Example script
Content type: text/plain
Description: IPN
Class: Payment Gateway Library
Accept payments with Paypal, and 2CO
Author: By
Last change: N/A
Date: 13 years ago
Size: 585 bytes


Class file image Download

// Include the paypal library
include_once ('Authorize.php');

// Create an instance of the library
$myAuthorize = new Authorize();

// Log the IPN results
$myAuthorize->ipnLog = TRUE;

// Specify your authorize login and secret
$myAuthorize->setUserInfo('YOUR_LOGIN', 'YOUR_SECRET_KEY');

// Enable test mode if needed

// Check validity and write down it
if ($myAuthorize->validateIpn())
file_put_contents('authorize.txt', 'SUCCESS');
file_put_contents('authorize.txt', "FAILURE\n\n" . $myAuthorize->ipnData);