Forked from strangerstudios/my_pmpro_text_translation.php
Last active
November 14, 2017 14:26
-
-
Save andrewlimaza/6da70f526207f9f445e8c78548aa0458 to your computer and use it in GitHub Desktop.
my_pmpro_text_translation
This file contains hidden or 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
<?php | |
/* | |
Change term "membership" to "subscription" for plugin generated text | |
*/ | |
function my_pmpro_gettext_membership($translated_text, $text, $domain) | |
{ | |
if($domain == "paid-memberships-pro") | |
{ | |
$translated_text = str_replace("Membership", "Subscription", $translated_text); | |
$translated_text = str_replace("membership", "subscription", $translated_text); | |
} | |
return $translated_text; | |
} | |
add_filter("gettext", "my_pmpro_gettext_membership", 10, 3); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment