1. Go to this page and download the library: Download licensespring/paypal library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
licensespring / paypal example snippets
// your script will return JSON string
header("Content-type:application/json");
// nce, if your PHP script is in /api/ folder relative to the document root then use: ew LicenseSpring\Webhook("insert-your-UUID-here", "insert-your-shared-key-here");
// capture any POST data (should be from your frontend part)
$frontend_payload = file_get_contents("php://input");
// this obtains license keys from LicenseSpring platform and returns response to frontend.
echo $webhook->acquireLicenses($frontend_payload);
// your script will return JSON string
header("Content-type:application/json");
// nce, if your PHP script is in /api/ folder relative to the document root then use: ew LicenseSpring\Webhook("insert-your-UUID-here", "insert-your-shared-key-here");
// capture any POST data (should be from your frontend part)
$frontend_payload = file_get_contents("php://input");
// this creates order in LicenseSpring platform and returns response to frontend.
echo $webhook->createOrder($frontend_payload);
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.