eventorganiser_booking_notification_email
(filter)
Pro
Filter the emails to which booking notifications (for site admins) are sent
Important: Filters an array of emails, not a string as filtered by eventorganiser_admin_email.
This allows you to send booking notifications to multiple email addresses.
function my_booking_notification_email( $emails, $booking_id ){
$event_id = eo_get_booking_meta( $booking_id, 'event_id' );
$organiser_id = get_post_field( 'post_author', $event_id );
$user_obj = get_userdata( $organiser_id );
if( $user_obj ){
$emails[] = $user_obj->user_email;
}
return $emails;
}
add_filter( 'eventorganiser_booking_notification_email', 'my_booking_notification_email', 10, 2 )
Parameters
array
|
|
List of emails to send the notification to. Defaults to {@see eo_get_admin_email()}
|
Example Usage
add_filter( 'eventorganiser_booking_notification_email', 'my_callback_function', 10, 1 );
function my_callback_function( ){
//Change first value and return it
return
};
Resources