This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// NSStringFolded.h | |
// | |
// Created by Thomas Tempelmann on 31 Jan 2024. | |
// Author retains no copyright - given to public domain | |
// | |
// Purpose: Provide a way to have case insensitive keys in an NSDictionary | |
// (see https://stackoverflow.com/a/77914964/43615) | |
// |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// https://developer.paddle.com/webhooks/signature-verification shows code using a `Verifier` class | |
// to check that the message from Paddle is authentic. | |
// Sadly, it doesn't explain where the value for the `$request` variable comes from. It seems you need to use | |
// the PSR framework for that, but I was unable to find a way to use it for getting the data for the POST | |
// I am handling in my webhook handler. | |
// Fortunately, I was able to resolve this by looking into the code of the Verifier class from the SDK. | |
// Here's a version that does not rely on PSR. You still haveo to install Paddle's PHP SDK, though, | |
// see https://github.com/PaddleHQ/paddle-php-sdk/ | |
require_once 'vendor/autoload.php'; // the path to your vendor dir created with "composer" tool |
OlderNewer