fc_pro_before_order_details_section_{section_id}
Type: Action
Fires before the contents of an order details section.
The dynamic portion of the hook name, $section_id, is the order details section ID. Possible hook names include:
fc_pro_before_order_details_section_customer_informationfc_pro_before_order_details_section_delivery_informationfc_pro_before_order_details_section_downloadsfc_pro_before_order_details_section_gift_messagefc_pro_before_order_details_section_licensesfc_pro_before_order_details_section_order_detailsfc_pro_before_order_details_section_order_notesfc_pro_before_order_details_section_order_statusfc_pro_before_order_details_section_order_summaryfc_pro_before_order_details_section_payment_methodfc_pro_before_order_details_section_subscriptions
Signature
do_action( 'fc_pro_before_order_details_section_{section_id}', $section_id );
Parameters
| Name | Type | Description |
|---|---|---|
$section_id | string | Section ID. |
Since
1.3.0
Source: inc/order-details.php
Examples
In fc_pro_before_order_details_section_{section_id}, order_summary replaces {section_id}.
add_action( 'fc_pro_before_order_details_section_order_summary',
/**
* Add promotional message before order summary section.
*
* @param string $section_id Section ID.
*/
function( $section_id ) {
echo '<div class="promotional-message">';
echo '<p>' . esc_html__( 'Thank you for your purchase! Enjoy 10% off your next order.', 'text-domain' ) . '</p>';
echo '</div>';
},
10
);