Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
gettext change level cost text
<?php
// Add this code below to your PMPro Customizations plugin - http://www.paidmembershipspro.com/create-a-plugin-for-pmpro-customizations/
add_filter( 'gettext', 'change_my_cost_example', 20, 3 );
/**
* @link http://codex.wordpress.org/Plugin_API/Filter_Reference/gettext
*/
function change_my_cost_example( $translated_text, $text, $domain ) {
switch ( $translated_text ) {
case 'The price for membership is <strong>%s</strong> now' :
$translated_text = __( 'The price for membership is <strong>%s</strong> today.', 'paid-memberships-pro' );
break;
case 'and then <strong>%s after %d %s</strong>' :
$translated_text = __( 'After your 365 day FREE listing only $15.00 per month.', 'paid-memberships-pro' );
break;
}
return $translated_text;
}
@andrewlimaza
Copy link
Author

andrewlimaza commented Apr 27, 2020

Update, to adjust the membership price text. Please use https://www.paidmembershipspro.com/add-ons/pmpro-custom-level-cost-text/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment