WordPress.org

Ready to get started?Download WordPress

Forums

Polylang
[resolved] String Translation in Responsive 1.9.3 (4 posts)

  1. Ulrich
    Member
    Posted 1 year ago #

    Hi Chouby,

    With the latest update of Responsive 1.9.3 we seem to have broken something with the compatibility with Polylang. The home page strings are not showing. When I use the plugin you created before the compatibility with WPML xml it works.

    WPML works fine with the new update. I am not sure where the problem lies. I hope we can solve this together.

    Ulrich

    http://wordpress.org/extend/plugins/polylang/

  2. Chouby
    Member
    Plugin Author

    Posted 1 year ago #

    Hi Ulrich,

    I just tested Responsive 1.9.3 + Polylang 1.0.4 and confirm the problem. It comes from the suppression of the line 29 in front-page.php

    $responsive_options = responsive_get_options();

    Since $responsive_options is global, it seems logical not to reload it but it is most probably loaded before Polylang sets the language and so not filtered by Polylang. WPML sets the language sooner and thus is not affected by this change.

    Which hook is used to set the language ?
    WPML -> 'plugins_loaded', priority 1
    Polylang, when setting the language from URL -> 'setup_theme', priority 5
    Polylang, when setting the language from content -> 'wp', priority 5

    For future, I plan to modify 'setup_theme', 5 to 'plugins_loaded', 1 when the language is set from url. It will improve the compatibility with some plugins and themes which also load strings very soon.

    But for the other option, I am stuck to a late hook.

    So for best compatibility, the strings should not be loaded before the 'wp' hook has been fired.

  3. Ulrich
    Member
    Posted 1 year ago #

    Hi Chouby,

    Thanks, we needed to remove the code in line 29 but will look if we can improve anything.

  4. Ulrich
    Member
    Posted 1 year ago #

    Hi Chouby,

    We have fixed the front page and with version 1.9.3.1 it should be working again.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.