Action
rpress_order_details_modal_actions
On this page
Fires inside the footer of the order details popup to add action buttons.
Runs in the order details template shown in the popup, such as Track order or Receipt from the account hub. Output is captured in a buffer; when anything is printed it is wrapped in a footer element. Callbacks must escape their own output.
Available since RestroPress 3.5.
Parameters#
| Parameter | Type | Description |
|---|---|---|
$payment_id | int | Order ID. |
Example#
function my_order_modal_actions( $payment_id ) {
printf(
'<a class="button" href="%s">%s</a>',
esc_url( add_query_arg( 'order', $payment_id, home_url( '/support/' ) ) ),
esc_html__( 'Get help', 'my-plugin' )
);
}
add_action( 'rpress_order_details_modal_actions', 'my_order_modal_actions' );
Notes#
The argument passed is $payment->ID.
Source#
Fired from:
templates/rpress-show-order-details.php(line 221)
See also#
Was this page helpful?
