GDPR Cookie Consent plugin helps you make your WordPress website easily comply with the Cookie Law. It helps you display a notification bar on the website that notifies the users of the cookies used on a website. The users can then give their consent to the use of the cookies on the website.
The text displayed in the cookie bar by default is in English. This is not ideal for multilingual websites where people visit the pages of the website in multiple languages. Favorably, the GDPR Cookie Consent plugin is compatible with most of the popular translation plugins like the following:
- WPML Read more…
- Polylang Read more…
- qTranslateX etc.
qTranslate X is a popular free WordPress plugin that helps owners with the translation of their website’s content. This article describes how you can change the content of the cookie bar depending on the language of the website. If you have installed and activated the GDPR Cookie Consent plugin and qTranslate plugin on your website, read on to know how to translate the cookie notification bar.
How to translate the cookie message in the notification bar with qTranslate?
To translate the cookie message to be displayed on the front end, go to the admin side of your website and navigate to GDPR Cookie Consent > Cookie Law Settings. From the Cookie Law Settings page, go to the Customise Cookie bar tab.
From the Message text area, add the message of the cookie notice that you want to display. Now to change the message of the cookie according to the selected language of the website, what you need to do is add the translated message in the same text area and encode the message with their corresponding language code.
There are three different ways with which the text can be encoded. They are as given below.
- Square bracket encoding
'['
. For example, [:en]Message text[:] - Swirly bracket encoding
'{'
. For example, {:en}Message text{:} - Comment encoding
'<'
. For example, <–:en–>Message text<–:–>
Where ‘en’ is the language code for English.
The below screenshot shows how this is done for a website with two languages – English and German. The cookie message text area contains messages in both languages encoded within corresponding language codes.
To translate the other strings in the cookie bar, the same approach can be used. For example, to translate the Accept button to the selected language, encode the button text within the corresponding language code and the translation as shown in the screenshot below.
So when the site is viewed in different languages, the content in the message bar also changes accordingly. The below screenshot shows the website viewed in English and cookie message also in English.
The below screenshot shows the website viewed in German and the cookies bar message also in the selected language.
The GDPR Cookie Consent plugin can be found here.
If you have any question/issues regarding the plugin, you can contact our support team here.
Arunas
June 1, 2021
I am using qTranslate-XT for translation (this is new fork of qTranslate-X with similar idea). Translation of buttons and banner works but translation of Privacy Overview (title, text, categories in the popup) does not work and just display full text with tags. For example the title of the popup looks like [:en]Privacy Overview[:lt]Privatumo Nustatymai[:]
Mark
June 16, 2021
Hi Arunas,
We haven’t currently tested the plugin with qTranslate XT. We will add it to backlogs.
will
April 1, 2022
but how is it done, the instructions above are only for editable text, but what about the plugin text that isnt editable. you have translations, but english is being used even when the site language is set to italian.
Mark
April 18, 2022
Hi @ Will,
If the site language is Italian and the translation for static texts is still in English then that translation may not be included within the language file. Please contact our support to resolve this.
Gábor Németh
March 2, 2021
How to translate Save & Accept button?
Mark
March 4, 2021
Hi,
Kindly mention which version of the plugin are you using and which language do you need translations for.
David
March 30, 2021
Same question as Mark´s on v. 2.0.1 English to Slovenian – Save & Accept = shrani in sprejmi
Mark
April 1, 2021
Hi David,
You may please add the translation of the button text here and once it is approved by moderators, you can use it.
will
April 1, 2022
Italian is fully translated. How do i set the language in functions.php to force cookieyes to show the translation of text items like save & accept?
Mark
April 18, 2022
Hi @ Will,
Greetings from Webtoffee!
The translation of static elements in UI like Save & Accept button text is translated automatically without the need for translation plugins. So, please choose your default language as Italian and it will translate automatically that text.
Mina Cevallos Ochoa
December 2, 2020
How to translate the cookie categories?
I am heaving problems to make it work as it does with WPML and Polylang.
Mark
December 7, 2020
Hi Mina,
Which plugin are you using for translation?
Kwent
September 16, 2020
Hi!
I’d like to know if this plugin works with Weglot plugin, and if yes, how do I configure it?
Thanks a lot for your help
Mark
September 17, 2020
We are not sure about the configuration with Weglot as we have never tested it. You may check with our free version plugin.
Massimo
March 8, 2020
Consent on GDPR cookies is important, but why use WordPress? It is one of the worst solutions for users, very difficult to edit and very heavy (therefore penalized by Google – see https://developers.google.com/speed/pagespeed/insights/)
Mark
March 9, 2020
This article is related to our WordPress plugin GDPR Cookie Consent plugin. You can check out this service if you have a different platform.
Tiberiu Porojan
February 16, 2020
Hi,
This “Privacy Overview” – This website uses cookies to improve your experience while you navigate through the website. Out of these cookies, the cookies that are categorized as necessary are stored on your browser as they are essential for the working of basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website. These cookies will be stored in your browser only with your consent. You also have the option to opt-out of these cookies. But opting out of some of these cookies may have an effect on your browsing experience.” has to be translated in Romanian, but I can not do it. Can you please explain?
Thanks!
Andras
August 22, 2019
Any chance to translate Privacy & Cookies Policy part? Regards!
Mark
August 22, 2019
Hi,
The text you are referring to is under Cookie Law Settings > General > Show Again Tab > Show More Text. You can translate it as you translate all general strings using the multilanguage plugin you are using.