• Resolved sonmar

    (@soniamariano)


    Hello,
    I’m using WP Ultimate Post Grid in a multilingual site. The grid is working fine, the same grid shows only the EN posts in my EN site version and only the PT posts in my PT site version. However, I need to be able to translate the “All Terms” button text. Is it possible? Or do I need to have a grid for my EN site an another one for my PT site?
    Thank you!

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Brecht

    (@brechtvds)

    You’ll have to create a separate grid for the different languages and change the text there.

    Thread Starter sonmar

    (@soniamariano)

    @brechtvds Thank you for your time with this. I tried something that worked and thought of sharing it with you. I discovered that the field were we insert the text string accepts shortcodes, so I made a custom shortcode that checks the site language and outputs a text accordingly.

    function mstgrid_see_all_filter_string() { 
    $currentlang = get_bloginfo('language');
    	if($currentlang=="en-GB") {
    		$seeallstring = 'All';}
    	else {
    		$seeallstring = 'Todas';}
        return $seeallstring;
    }
    add_shortcode( 'odcs_mstgrid_see_all_filter_string', 'mstgrid_see_all_filter_string' );

    Then I inserted [odcs_mstgrid_see_all_filter_string] in the All terms button box and voila! One grid fits both my EN and my PT site!

    Plugin Author Brecht

    (@brechtvds)

    That’s a good solution, happy to hear that works for you and thanks for sharing!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘All Terms button translation’ is closed to new replies.