Skip to content
Docs
Get RestroPress

Filter

rpress_reservation_email_defaults

Updated
On this page

Filters the default subject, body and label for each reservation email type.

Runs in rpress_reservation_email_defaults(). The array is keyed by email type (received, confirmed, declined, reminder, admin), each with label, subject and body. The defaults are used when the matching setting is empty. Bodies and subjects can contain tags such as {name}, {date}, {time} and {party_size}.

Parameters#

ParameterTypeDescription
$defaultsarrayType to array( 'label', 'subject', 'body' ).

Return value#

array. Defaults per email type.

Example#

function my_reservation_email_defaults( $defaults ) {
	$defaults['confirmed']['subject'] = __( 'Table booked at {sitename}', 'my-plugin' );
	return $defaults;
}
add_filter( 'rpress_reservation_email_defaults', 'my_reservation_email_defaults' );

Source#

Applied in:

  • includes/features/reservations/emails.php (line 24), in rpress_reservation_email_defaults()

See also#

Was this page helpful?