Changing title text

Home Forums Welcome! Pre-Sales Questions Changing title text

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #1453325
    Ed Croteau
    Guest

    I see this KB : https://theeventscalendar.com/knowledgebase/change-the-wording-of-any-bit-of-text-or-string/

    but it doesn’t seem to work for me here : almostjanet.com/events

    Here’s my function.php code :

    function tribe_custom_theme_text ( $translation, $text, $domain ) {

    $custom_text = array(
        'Upcoming Events' => 'Upcoming Shows',
    );
    // If this text domain starts with "tribe-", "the-events-", or "event-" and we have replacement text
        if( (strpos($domain, 'tribe-') === 0 || strpos($domain, 'the-events-') === 0 || strpos($domain, 'event-') === 0) && array_key_exists($translation, $custom_text) ) {
        $translation = $custom_text[$translation];
    }
    return $translation;
    

    }
    add_filter('gettext', 'tribe_custom_theme_text', 20, 3);

    Please advise.

    #1454551
    Patricia
    Member

    Hey Ed,

    Thank you for reaching out to us!

    To achieve what you want you have to replace ‘Upcoming Events’ with ‘Upcoming %s’.

    We are unfortunately unable to provide support through our Pre-Sales forum channel so if you have any other questions, please head over to The Events Calendar WordPress.org support forums for assistance and answers.

    If you have a PRO license, you can log into your account and get assistance through the PRO forums. If you need to reset your password, you can do so here. This will send an email to the account used when you initially registered for the support forums.

    Best regards,

    Patricia

Viewing 2 posts - 1 through 2 (of 2 total)
  • The topic ‘Changing title text’ is closed to new replies.