Hi,
I try to change the subject line for admin emails when tickets are sold with woocommerce.
At the moment I have the following:
add_filter('woocommerce_email_subject_new_order', 'change_admin_email_subject', 1, 2);
function change_admin_email_subject( $subject, $order ) {
global $woocommerce;
$event_title = do_action( 'woocommerce_email_order_details', $order, $sent_to_admin, $plain_text, $email );
$subject = sprintf( 'New Ticket sold for the event: ' . $event_title );
return $subject;
}
This doesn’t work beacuse I don’t get $event_title filled.
Could you please help me here?
Many thanks in advance!