Change Link lable

Home Forums Calendar Products Events Calendar PRO Change Link lable

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #1083730
    Johan
    Participant

    Hello, on my events list page (in swedish) a llik says Mer information »
    I want to change this to Läs mer. How do I do that?

    • This topic was modified 10 years, 1 month ago by Johan.
    #1084112
    Brian
    Member

    Hi,

    Thanks for using our plugins. I can help out here.

    We have this guide to changing words to anything you like:

    https://theeventscalendar.com/knowledgebase/changing-the-word-events-to-something-else/

    You would want to change the English string:

    Find out more

    Let me know if you have any follow up questions.

    Thanks

    #1084535
    Johan
    Participant

    Hello I think you may have linked to the wrong page. But no worries I found the right one. (The one you linked to only changes the word Event i think?)

    So I changed Find out more to Läs mer but there is an » after the link that I want to ger rid of, How do I do that?

    #1084561
    Brian
    Member

    Yeah I meant to link to this one:

    Custom Wording in the Calendar

    Sorry about that.

    If you want to remove the double right arrows you have to change the template following our themer’s guide:

    https://theeventscalendar.com/knowledgebase/themers-guide/

    Following that you want to move this tempalte:

    plugins/the-events-calendar/src/views/list/single-event.php

    to your theme:

    yourtheme/tribe-events/list/single-event.php

    Then you will want to delete this:

    »

    #1084754
    Johan
    Participant

    Hi there. I added this code and it worked – it changed my word.
    But after that Events Calendar change Language compleatly from Swedish to English in the admin and everywhere
    How do I prevent that?

    /*
     * EXAMPLE OF CHANGING ANY TEXT (STRING) IN THE EVENTS CALENDAR
     * See the codex to learn more about WP text domains:
     * http://codex.wordpress.org/Translating_WordPress#Localization_Technology
     * Example Tribe domains: 'tribe-events-calendar', 'tribe-events-calendar-pro'...
     */
    function tribe_custom_theme_text ( $translations, $text, $domain ) {
     
    	// Put your custom text here in a key => value pair
    	// Example: 'Text you want to change' => 'This is what it will be changed to'
    	// The text you want to change is the key, and it is case-sensitive
    	// The text you want to change it to is the value
    	// You can freely add or remove key => values, but make sure to separate them with a comma
    	// This example changes the label "Venue" to "Location", and "Related Events" to "Similar Events"
    	$custom_text = array(
    		'Find out more' => 'Läs mer',
    	);
     
    	// If this text domain starts with "tribe-" or "the-events-", and we have replacement text
    	if((strpos($domain, 'tribe-') === 0 || strpos($domain, 'the-events-') === 0) && array_key_exists($text, $custom_text) ) {
    		$text = $custom_text[$text];
    	}
     
    	return $text;
    }
    add_filter('gettext', 'tribe_custom_theme_text', 20, 3);
    #1085179
    Brian
    Member

    Hi,

    I am not sure why it would be that way.

    If so I would just edit the text directly in this template where you edited the right arrows?:

    yourtheme/tribe-events/list/single-event.php

    Does that work for this time at least?

    #1091382
    Support Droid
    Keymaster

    This topic has not been active for quite some time and will now be closed.

    If you still need assistance please simply open a new topic (linking to this one if necessary)
    and one of the team will be only too happy to help.

Viewing 7 posts - 1 through 7 (of 7 total)
  • The topic ‘Change Link lable’ is closed to new replies.