Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
  • #20844

    A good morning,

    I’d like to add the following google translate codes to my website:

    Google states: Copy and paste the following code snippets onto every page you want to translate

    Place this meta tag before the closing </head>

    <meta name=”google-translate-customization” content=”d9ca985f1f4914af-ba2cff8f281e9034-g5e2983121a63bbb1-b”></meta>


    Place this snippet where you’d like to display the Website Translator plugin on your page

    <div id=”google_translate_element”></div><script type=”text/javascript”>

    function googleTranslateElementInit() {

    new google.translate.TranslateElement({pageLanguage: ‘nl’, layout: google.translate.TranslateElement.InlineLayout.HORIZONTAL}, ‘google_translate_element’);


    </script><script type=”text/javascript” src=”//”></script>

    I’d like to know where exactly to place the above mentioned codes. (I’m using Propulsion)

    Thank you in ad,




    I suggest you use this plugin instead..




    Thanks Ismael,

    May I know why you’d prefer this plugin?

    Secondly, I don’t use sidebars on my site and having the translator in the sidebar location would break the intended look of my webpages. Should your answer to my question above be that the plugin is faster and better in many ways as compared to the google-adviced option, then could you show me how to make the translator of the plugin appear smaller and on the on the pages (instead of sidebar)?


    Hi Khoel,

    The plugin is just a bit easier to implement because it typically just has to be installed. Because you want to customize it a bit, you can use either option.

    What you want to do to add it in via code is to put the code for the head in the header.php file just before the close of </head>.

    Then, decide where you want the google translate button/widget to appear. If you want it in the header as well, then it would go in the header.php somewhere in the html structure.




    Thanks Devin….I´ll do just that.

Viewing 5 posts - 1 through 5 (of 5 total)

The topic ‘How can I add google translate codes’ is closed to new replies.