Skip to content

Instantly share code, notes, and snippets.

@yuriinalivaiko
Created November 6, 2022 20:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save yuriinalivaiko/39f5bc117b68b2720695cf62aa9d6004 to your computer and use it in GitHub Desktop.
Save yuriinalivaiko/39f5bc117b68b2720695cf62aa9d6004 to your computer and use it in GitHub Desktop.
Hook um_before_email_template_part
<?php
/**
* Hook: um_before_email_template_part
*
* Type: action
*
* Description: Fires before email template loading.
* May be used to display custom content above the main email message.
*
* @example https://github.com/ultimatemember/ultimatemember/blob/master/includes/core/class-mail.php#L218
* @link https://docs.ultimatemember.com/article/1058-umbeforeemailtemplatepart
*
* @package um\core
* @see um\core\Mail::get_email_template()
* @since 2.0
* @deprecated since version 3.0
*
* @param string $template Template key.
* @param string $template_path Template location.
* @param array $args Template settings.
*/
function my_before_email_template_part( $template, $template_path, $args ) {
// your code here.
}
add_action( 'um_before_email_template_part', 'my_before_email_template_part', 10, 3 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment