Function __global->handle_pdt_ipn_transaction_script
Definitions
sources/ecommerce.php
- Handle PDT's and IPN's.
- Visibility: public
- Is abstract?: No
- Is static?: No
- Is final?: No
- Returns: string
Parameters
| Name | Type | Passed by reference? | Variadic? | Default | Set | Range | Description |
|---|---|---|---|---|---|---|---|
| $silent_fail | boolean | No | No | False | N/A | N/A | Return null on failure rather than showing any error message. Used when not sure a valid & finalised transaction is in the POST environment, but you want to try just in case (e.g. on a redirect back from the gateway). |
| $send_notifications | boolean | No | No | True | N/A | N/A | Whether to send notifications. Set to false if this is not the primary payment handling (e.g. a POST redirect rather than the real IPN). |
Returns
- The ID of the purchase-type (meaning depends on item_name) (null: unknown)
- Type: ?ID_TEXT
- Set: N/A
- Range: N/A
Preview
Code (PHP)
/**
* Handle PDT's and IPN's.
*
* @param boolean $silent_fail Return null on failure rather than showing any error message. Used when not sure a valid & finalised transaction is in the POST environment, but you want to try just in case (e.g. on a redirect back from the gateway).
* @param boolean $send_notifications Whether to send notifications. Set to false if this is not the primary payment handling (e.g. a POST redirect rather than the real IPN).
* @return ?ID_TEXT The ID of the purchase-type (meaning depends on item_name) (null: unknown)
*/
function handle_pdt_ipn_transaction_script(bool $silent_fail = false, bool $send_notifications = true) : ?string
* Handle PDT's and IPN's.
*
* @param boolean $silent_fail Return null on failure rather than showing any error message. Used when not sure a valid & finalised transaction is in the POST environment, but you want to try just in case (e.g. on a redirect back from the gateway).
* @param boolean $send_notifications Whether to send notifications. Set to false if this is not the primary payment handling (e.g. a POST redirect rather than the real IPN).
* @return ?ID_TEXT The ID of the purchase-type (meaning depends on item_name) (null: unknown)
*/
function handle_pdt_ipn_transaction_script(bool $silent_fail = false, bool $send_notifications = true) : ?string

