Support » Plugin: Translate WordPress - Google Language Translator » Only works when logged in

  • Resolved farberama

    (@farberama)


    The plugin only translates the page when logged in. If not logged, I get this error in the console when clicking the flag:

    scripts.js?ver=6.0.12:50 Uncaught TypeError: Cannot set properties of undefined (setting 'value')
        at doGoogleLanguageTranslator (scripts.js?ver=6.0.12:50)
        at n (scripts.js?ver=6.0.12:375)
        at HTMLAnchorElement.<anonymous> (scripts.js?ver=6.0.12:370)
        at HTMLBodyElement.dispatch (jquery.min.js?ver=3.6.0:2)
        at HTMLBodyElement.v.handle (jquery.min.js?ver=3.6.0:2)

    The site is ddrb.org

    • This topic was modified 3 months ago by farberama.
    • This topic was modified 3 months ago by farberama.
Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Author edo888

    (@edo888)

    Hi,

    Which caching plugin do you use?

    Thanks! πŸ™‚

    Thread Starter farberama

    (@farberama)

    wp rocket

    Plugin Author edo888

    (@edo888)

    Are you using the latest version of our plugin?

    Thread Starter farberama

    (@farberama)

    I’m using v. 6.0.12

    I just tested it and when I set Enable caching for logged-in WordPress users it stops working. So, it appears it is an issue with wp rocket caching.

    I then added /wp-content/plugins/google-language-translator/js/(.*) to the Excluded JavaScript Files, but that didn’t help.

    Plugin Author edo888

    (@edo888)

    Hi,

    It is strange, because recently we have made sure that our scripts are not getting cached by WP Rocket, here is a changelog: https://plugins.trac.wordpress.org/changeset/2608992/google-language-translator

    This makes sure that translate.google.com/translate_a/element.js is not getting cached locally by WP Rocket.

    Maybe you are using an old version of WP Rocket? I would recommend you to contact their support and ask why that happens and share their comments. It will help us to fix any code on our end if something is not right.

    Thanks! πŸ™‚

    Thread Starter farberama

    (@farberama)

    the first thing I did when I noticed the problem was update everything including wp rocket. I’m on version 3.10.1

    Plugin Author edo888

    (@edo888)

    To solve the issue this script must be excluded: translate.google.com/translate_a/element.js

    If you want to help others, please contact their support and ask why that is not getting excluded.

    Hi,

    I am getting same error when clicking the flag. I have use Divi Builder to built website. I am not using any cache plugin. This plugin was working fine before last update but now it is not translating. I am mentioning here 2 URL with old version (Version 6.0.11) and new version (Version 6.0.12).

    Old Version (working URL): https://demo2.onetopsolution.com/kt/
    New Version (not working): http://www.kashmirtraders.com/

    Kindly check what’s wrong.

    Thanks,

    • This reply was modified 2 months, 3 weeks ago by infoots.
Viewing 8 replies - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.