Diff: STRATO-apps/wordpress_03/app/wp-content/plugins/paid-memberships-pro/includes/email-templates.php

Keine Baseline-Datei – Diff nur gegen leer.
Zur Liste
1 -
1 + <?php
2 +
3 + // File used to setup default email templates data.
4 + global $pmpro_email_templates_defaults;
5 +
6 + $check_gateway_label = get_option( 'pmpro_check_gateway_label' ) ? get_option( 'pmpro_check_gateway_label' ) : esc_html__( 'Check', 'paid-memberships-pro' );
7 +
8 + // Default email templates.
9 + $pmpro_email_templates_defaults = array(
10 + 'default' => array(
11 + 'subject' => esc_html__( "An email from !!sitename!!", 'paid-memberships-pro' ),
12 + 'description' => esc_html__( 'Default Email', 'paid-memberships-pro'),
13 + 'body' => esc_html__( '!!body!!', 'paid-memberships-pro' ),
14 + 'help_text' => esc_html__( 'This email is sent when there is a general message that needs to be communicated to the site administrator.', 'paid-memberships-pro' )
15 + ),
16 + 'footer' => array(
17 + 'subject' => '',
18 + 'description' => esc_html__( 'Email Footer', 'paid-memberships-pro'),
19 + 'body' => wp_kses_post( '<p>' . esc_html__( 'Respectfully,', 'paid-memberships-pro' ) . '<br />!!sitename!! </p>' ),
20 + 'help_text' => esc_html__( 'This is the closing message included in every email sent to members and the site administrator through Paid Memberships Pro.', 'paid-memberships-pro' )
21 + ),
22 + 'header' => array(
23 + 'subject' => '',
24 + 'description' => esc_html__( 'Email Header', 'paid-memberships-pro'),
25 + 'body' => wp_kses_post( sprintf( '<p>%s</p>', esc_html__( 'Dear !!header_name!!,', 'paid-memberships-pro' ) ) ),
26 + 'help_text' => esc_html__( 'This is the opening message included in every email sent to members and the site administrator through Paid Memberships Pro.', 'paid-memberships-pro' )
27 + ),
28 + );
29 +
30 + // Add any templates registered via the PMPro_Email_Template class.
31 + $registered_templates = PMPro_Email_Template::get_all_email_templates();
32 + $default_gateway = get_option( 'pmpro_gateway' );
33 + // if gateway is not stripe, remove the payment action emails
34 + if( 'stripe' !== $default_gateway ) {
35 + unset( $registered_templates['payment_action'] );
36 + unset( $registered_templates['payment_action_admin'] );
37 + }
38 + foreach ( $registered_templates as $registered_template_slug => $registered_template_class ) {
39 + $pmpro_email_templates_defaults[ $registered_template_slug ] = array(
40 + 'subject' => $registered_template_class::get_default_subject(),
41 + 'description' => $registered_template_class::get_template_name(),
42 + 'body' => $registered_template_class::get_default_body(),
43 + 'help_text' => $registered_template_class::get_template_description(),
44 + );
45 + }
46 +
47 + /**
48 + * Filter default template settings and add new templates.
49 + *
50 + * @since 0.5.7
51 + */
52 + $pmpro_email_templates_defaults = apply_filters( 'pmproet_templates', $pmpro_email_templates_defaults );
53 +