Transalting Content Dock

Hello,
I need translating “Do not show again” in Content Dock extension.

Can you please help with the file?

Mauro

Hello Mauro,

Thanks for asking. :slight_smile:

This will require changes in theme files. To do that please setup child theme using following resource.

  1. Download child theme from here. https://theme.co/apex/child-themes
  2. Child theme docs: https://theme.co/apex/forum/t/setup-how-to-setup-child-themes/57

After that add following code in child theme function.php file:

add_filter( 'gettext', 'change_texts', 20, 3 );
function change_texts( $translated_text, $text, $domain ) {
        switch ( $translated_text ) {
            case 'Do not show again' :
                $translated_text = __( 'Enter Text Here', '__x__' );
                break;                           
        }
    return $translated_text;
}

Please replace Enter Text Here with your text.

Hope that helps.

2 Likes

Thank you!

Work fine for me!

It can be useful for anyone who wants to use the Content Dock for GDPR.

Best Regards,

Mauro

1 Like

You are most welcome, Mauro. :slight_smile:

Prasant,
sorry to disturb you again.

I find a little bug updating my websites with Content Dock.

Please, you can visit https://blog.europlantsvivai.com and scroll down until the footer, where you can see the bug.

Do you have, please, some advice?

Mauro

Hi Mauro,

Upon testing, I can see that the content dock is working on other pages. Could you please try disabling your other 3rd party plugins and see if your issue is related to a plugin conflict.

Also if you’re using a caching plugin, make sure to purge your server cache as well.

Let us know how it goes.
Thanks!

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.