English (United Kingdom)
Knowledge Base  >  Vik Appointments  >  Hooks  >  Site Pages  >  Order  >  Display Summary

apply_filters( 'vikappointments_display_order_summary', string $html, object $order )

Fires after displaying all the booked appointments.


Description

Trigger hook to let the plugins add custom HTML contents below the order summary. The returned HTML will be always included outside the form of the page.

Our VikAppointments - Zoom plugin uses this hook to display the button to start the meeting on site.

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


Parameters

$html

(string)  The HTML to include.

$order

(VAPOrderAppointment)  The instance holding the order details.


Example

/**
 * Trigger event to let the plugins add custom HTML contents below the order summary.
 *
 * @param  string  $html   The HTML string to include within the document.
 * @param  object  $order  The object holding the appointments details.
 */
add_filter('vikappointments_display_order_summary', function($html, $order)
{
    // append custom HTML
    $html .= '<code>HTML CODE WILL BE ADDED HERE</code>';

    return $html;
}, 10, 2);

Changelog

Version Description
1.2 Introduced.
Last Update: 2021-07-30
Helpful?
This site uses cookies. By continuing to browse you accept their use. Further information