/**
* Customize the reminder email text
*/
function my_picu_reminder_email_content( $mail_parts, $mail_context, $collection_id ) {
if ( $mail_context == 'client_reminder' && class_exists( 'Picu_Emails' ) ) {
$picu_mail = new Picu_Emails( $collection_id );
// Replace mail part:
$mail_parts[0] = [
'type' => 'text',
'text' => $picu_mail->text_to_html( 'My custom text here' )
];
}
return $mail_parts;
}
add_filter( 'picu_mail_parts', 'my_picu_reminder_email_content', 10, 3 );
Code language: PHP (php)