Mailster has some internal texts which are used at various locations. By default, you can change them on the Text tab in the settings, but if you like a more flexible approach, you can simply change them by a hook via the mailster_text filter.

Available Text snippets

Key ($option)Default Value
confirmationPlease confirm your subscription!
successThanks for your interest!
errorFollowing fields are missing or incorrect
unsubscribeYou have successfully unsubscribed!
unsubscribeerrorAn error occurred! Please try again later!
profile_updateProfile updated!
newsletter_signupSign up to our newsletter
emailEmail
firstnameFirst Name
lastnameLast Name
listsLists
submitbuttonSubscribe
profilebuttonUpdate Profile
unsubscribebuttonYes, unsubscribe me
unsubscribelinkunsubscribe
webversionwebversion
forwardforward to a friend
profileupdate profile
already_registeredYou are already registered
new_confirmation_sentA new confirmation message has been sent
enter_emailPlease enter your email address
gdpr_textI agree to the privacy policy and terms.
gdpr_errorYou have to agree to the privacy policy and terms!
general_checks:Sorry, you cannot signup with this email address.
smtp_mx_checkWe weren’t able to check your email address.
blocked_emailSorry, your email address is not accepted!
blocked_domainSorry, you are not allowed to signup with this domain.
blocked_ipSorry, your IP address has been blocked from signing up.
blocked_countrySorry, your country has been blocked from signing up.

Change code programmatically

Add the following snippet to your site. (Learn how):

add_filter( 'mailster_text', function( $string, $option, $fallback ) {

    switch ( $option ) {
        case 'confirmation':
            $string = 'Please click on the link in your email confirmation';
        break;
    }

    return $string;

}, 10, 3 );

Each time a text string is needed, it runs through this method. If the $option is the “confirmation” it replaces the initial string with a new one. All other strings are bypassed and do not get changed.

Tagged: