public function onDisplayOrderPackageSummary(object $item, object $order) : string

Fires while displaying the details of a purchased package.


Description

Trigger hook to let the plugins add custom HTML contents within the block of a purchased package. This procedure repeats up to the number of purchased items.

The following image indicates where the resulting HTML can be appended.


Parameters

$item

(object)  The object holding the package details.

$order

(VAPOrderPackage)  The instance holding the order details.

Return Value

String. The HTML to include.


Example

/**
 * Trigger event to let the plugins add custom HTML contents within the block of the purchased package.
 *
 * @param   object  $item   The package details.
 * @param   object  $order  The purchased order.
 *
 * @return  string  The HTML string to include within the document.
 */
public function onDisplayOrderPackageSummary($item, $order)
{
    // append custom HTML after the package details
    return '<code>HTML CODE WILL BE ADDED HERE</code>';   
}

Changelog

VersionDescription
1.7 Introduced.
Last Update: 2021-10-11 10:03
Helpful?