Created
November 15, 2012 21:35
-
-
Save strangerstudios/4081449 to your computer and use it in GitHub Desktop.
Change Paid Memberships Pro Email Subjects
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Change email subjects. | |
The function checks $email->template and updates the subject as needed. | |
The email template name will be equivalent to the filenames in the /email/ folder of the PMPro plugin. | |
*/ | |
function my_pmpro_email_subject($subject, $email) | |
{ | |
//only checkout emails | |
if($email->template == "checkout_free") | |
{ | |
$subject = "Thank you, " . $email->data["name"] . ", for using " . get_bloginfo("name"); | |
} | |
return $subject; | |
} | |
add_filter("pmpro_email_subject", "my_pmpro_email_subject", 10, 2); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This recipe is included in the blog post on "Changing PMPro Email Subjects" at Paid Memberships Pro here: https://www.paidmembershipspro.com/changing-pmpro-email-subjects/